This is the mail archive of the
mailing list for the binutils project.
Re: ARM as ... possible bug
On 11/12/11 10:19, Dave Pawson wrote:
strexd r0, r1,r2,[r4]
arm.asm:275: Error: even register required -- `strexd r0,r1,r2,[r4]'
$arm-linux-elf-as -mcpu=arm1176jzf-s -mfpu=vfpv2 -o $1.o $1.asm
I can find nothing in
ARM v7-A and ARM v7-R edition
which indicates that any of the registers must be evenly numbered?
1. Which reg is wrong (unclear error message?)
r1 in your example is the register producing the error. In ARM state
the first register transferred must be an even numbered register, and
the second register transferred must be the register numbered one higher.
So strexd r0, r2, r3, [r4] is valid
But strexd r0, r2, r6, [r4] is not.
The ARMARM describes this in the ARM state encoding specific operations
(the pseudo-code that goes with the ARM state encoding).
2. Is it an error at all?
Gas is correct - although admittedly unclear.
 Thumb state doesn't have these particular restrictions, but strexd
is not available in Thumb state until ARMv7.
Principal Engineer, PD Software - Tools, ARM Ltd