[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gas: bad code: symbol as scale for indexed addressing
From: |
John Reiser |
Subject: |
gas: bad code: symbol as scale for indexed addressing |
Date: |
Tue, 24 Jul 2001 20:43:07 -0700 |
gas 2.11 generates bad relocatables, and gives no error message,
when a symbol is used as a scale factor on i586 under Linux.
GNU assembler 2.11
--host=i586-pc-linux-gnu --norecursion
Linux jreiser 2.2.19-6.2.1perf #1 Wed Jul 4 21:25:48 PDT 2001 i586 unknown
-----foo.s input file
foo = 8
leal 1(%eax,%ecx,foo),%edx # intending a scale factor of 8
-----
$ as-new -o foo.o foo.s ### note no messages
$ echo $? ### examine the exit code from as-new
0 ### success
$ gdb foo.o
(gdb) x/i 0
0x0: lea 0x1(%eax,%ecx,1),%edx ### scale factor is 1, not 8
(gdb) x/x 0
0x0: 0x0108548d ### should be 0x01c8548d
---- ----^--------------------------^
--
John Reiser, address@hidden
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gas: bad code: symbol as scale for indexed addressing,
John Reiser <=