user00011
user00011

Reputation: 123

Trace32 command to read symbol name for a given address from the ELF File

I used T32 to load bin files and elf and wrote scripts to extract the Pc , Lr register values from the ELF file. Now I have the address for e.g say PC's address is 0xccccdddd. Now I need to get the symbol corresponding to that. I ran gdb and used gdb info symbol 0xccccdddd and got the symbol name. But I need to know if there is any command in T32 itself to get the symbol name. Or can I get the symbol name from some commands like readelf or objdump. Thanks in advance.

Upvotes: 0

Views: 3493

Answers (1)

Holger
Holger

Reputation: 4183

The command to open a window to see all the static symbols is

sYmbol.Browse

To learn more about that window, I recommend to check the "Training HLL Debugging" (training_hll.pdf) from your TRACE32 installation.

To get only the symbol related to one single address use the PRACTICE function sYmbol.Name(<addr>). Functions have to be used together with a command. To simply display the name use the command PRINT.

E.g.:

PRINT sYmbol.Name(P:0xccccdddd)

Note that the address-offset has to be prefixed by an access class. Usually the access class "P:" stands for program memory, while "D:" stands for data memory. See the "Processor Architecture Manual" for more CPU specific access classes (Menu > Help > Processor Architecture Manual)

Upvotes: 3

Related Questions