Google
  Web www.spinics.net

VALUE OF VARIABLE FROM ARM REGISTER USING STACK FRAME BACKTRACE

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


Hi,
Can anybody suggest me how to get a value of a variable from ARMregister. I want to get the variable value in register while backtracing the stack frame.I can get the value of a local variable that isstored in stack, but I do have a problem if the variable is stored inARM register.

If the variable is in register, then, Is there anyspecific location for ARM registers in the Stack frame so that I can usethe frame pointer to retrieve the value of the variable.

Usingdwarf information, I can get that the variable is in register, butwhere in the stack frame the register is located that I have a problem?Because from dwarf info if I get that the variable is in stack, than Ican use the frame pointer and add location to the frame pointer and canget the value. But in case, if the variable is stored in register thanI cannot use the frame pointer of the stack frame. So how do I get thatvariable value?


For example, if I have a variable 'VAR'. Iwant to retrieve the value of this VAR by tracing the stack frame. Now ifthis variable was in stack while executing the function, I can get thelocation of the same in the stack frame and get the value. If the 'VAR'is stored in a register, say 'R2', than I need to know the location ofregister in the stack frame. So, how do I find out the value of thevariable in Register.

Regards
Ashim



      ____________________________________________________________________________________
Be a better friend, newshound, and 
know-it-all with Yahoo! Mobile.  Try it now.  http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
-------------------------------------------------------------------
List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm
FAQ:        http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette:  http://www.arm.linux.org.uk/mailinglists/etiquette.php

[Site Home]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux ARM Kernel]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Tools]     [DDR & Rambus]     [Monitors]

Powered by Linux

Google PageRank Checking tool