cancel
Showing results for 
Search instead for 
Did you mean: 

Confusing behavior of asm with memory

MLalu.1
Associate

I try to better understand assembly so I use STcubeIDE debugger to see how my C code is translate in asm langage. But I dont understand a thing. In the asm code I see that it regulary "jump" on memory addresses where there is nothing (only FFFFFFFF) or it is going to search or write data in non accessible memory (such as "0x2020202c" or "0x20202028"). The aim of my code is simply to use the button on my NUCLEO-64 board to blink the embedded green led. I was surprised to see that my asm code use the "non accessible memory adresses" instead of the GPIO registers adresses. Could someone help me to understand this behavior ?

4 REPLIES 4

Would seem some information is being misinterpreted somewhere.​

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Ozone
Lead II

I would say, either use a tool like objdump to create asm files, or step through with the debugger in instruction-step-mode.

You might misinterpret data oe empty sections.

Yeah, I'd start with a static analysis of the sources vs linker output disassembly, and then assess if the debugger or user is reporting cogent information. ​

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
MLalu.1
Associate

ok ... thank you ! I'm going to try with the debugger in instruction-step-mode to see where is my problem.