This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Thumb inline assembly


Thanks. Changing that line works. I had this code working in the
function directly as I was passing immediates. When this is called
through a function, it takes registers and I had to update it
accordingly.


On Mon, Jun 10, 2013 at 6:01 PM, Ian Lance Taylor <iant@google.com> wrote:
> On Mon, Jun 10, 2013 at 5:41 PM, Kalai Rajah N <kalairajah@gmail.com> wrote:
>
>> "ldr r1, =%0 /* load the nvic_iser* register */ \n\t"
>
> The references are coming from your lines like the above.  I don't
> know what this syntax means.  You are asking GCC to put a register
> name in there, so the result is something like
>     ldr r1, =r1
> This winds up referring to a symbol named r1, rather than the register r1.
>
> Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]