0

I am using IAR for Renesas . The problem I am facing is , I cannot set breakpoint at few lines. Though I recompile and load it multiple times , I am unable to set breakpoint at these lines. If I look at the map file, I do not find any memory allocated for these static variables which I am unable to set breakpoint. Is there any reason for memory being not allocated ?

Thanks

pranathi
  • 383
  • 4
  • 6
  • 16

1 Answers1

1

What optimisation level are you using?
Is it possible that the logic of your code has caused the entire section of code to be optimised away? The compiler will delete code that can never be reached. Look at the compiler assembly listing to see whether there is any code generated for the lines that you are interested in debugging.

uɐɪ
  • 2,540
  • 1
  • 20
  • 23
  • I am using the highest optimization level. I have to lower the level and check if that works . Thanks ! – pranathi Sep 09 '20 at 00:28
  • At higher optimisation levels it is often not possible to set a breakpoint at the required source line. If you look at the documentation int the IDE and compiler manuals this is explained. – uɐɪ Sep 09 '20 at 09:14