Forum Discussion
Altera_Forum
Honored Contributor
21 years agoLocal variables debugging
Hallo,
I have problem with function's local variable debugging. I'm trying watch function's local variable values in nios2-debug and also nios2-elf-gdb. Both of deguggers doesn't work with this variable, which has -1 value for all debbugging time and I'm not able to stepping program. Btw this variable has not static address in memory. Problem I mentioned is with 'irq_id' variable in example: int function(const void* xxx) { int irq_id = 0; /* cycle index */ for (irq_id = 0; irq_id < 32; irq_id++) { ... } return (NO_ERROR); } When I tried to declare function's local variable 'irq_id' as 'staic', debuggers works correctly, but I think that debuggers must work with 'auto' declared function's local variables... I'm using GNU based development tools only, not NiosII IDE. Thank you for some motive.No RepliesBe the first to reply