[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Is this a bug? Can do mov r0, #676

From: Jay Monkman
Subject: Re: Is this a bug? Can do mov r0, #676
Date: Sun, 02 Oct 2005 10:25:33 -0500
User-agent: Debian Thunderbird 1.0.2 (X11/20050817)

Daniel Jacobowitz wrote:
> On Sat, Oct 01, 2005 at 11:27:38AM -0500, Jay Monkman wrote:
>>I'm using a cross assembler for ARM, running on x86, and seeing something 
>>Here's the test program:
>>      mov     r0, #675

> You should take another look at the ARM instruction set documentation;
> immediate moves are limited to eight bits _plus a rotate_.

I understand that. I just didn't realize the assembler was outsmarting me. I
assumed the shift had to be explicitly listed in the assembly code. Now that I
look, I don't see any way to explicitly specify the shift.

I had thought the immediate argument could be 12 bits, so I was surprised when
one 12 bit value worked, but another didn't. When I reread the ARM
documentation, and I saw that the operand was limited to 8 bits, I was more

Thanks for helping un-confuse me.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]