I have a weird initialization order fiasco (at least it looks like that) that I wanted to solve using the Debugger. I’m new to that tool so when I pressed the “start” button, I got the following error:
I thought that’s a quick one as a “release” compile would give me smaller size but even with compiler optimization set to -Os (optimized for size) would still give me near 130% which is why I cannot debug
I assume I cannot reduce size more because the debugger just needs the symbols. Just a bit disappointing as for complex projects flash useage of >50% “release” mode will most likely kill any try for a debug session.
Are there other Ideas I could try? My UnitTests are fine and the Inspector also tells everything OK (well, apart from size…) Else, I’ll go down the long and painful road of printfs.
So what flash size do you have when you build it with release? Should be noticeably smaller due to the symbols not being built. I’m slowly starting to think that this is the way it is, and will start manual debugging tomorrow. Thanks for your extremely quick and engaged help!
I must make a mistake here. Does it really build in [env:debug] when I hit the button?
It somehow builds without optimizations. Will look into that tomorrow, your post shows there must be a solution for this.
Both “Inspect” and “Debug” options by default DO NOT use [env:debug] but instead use the normal release environment, for me in this environment this is [env:nanoatmega328] so when I add the debug build flags while keeping the build_type = release like this
Then the result is both a working inspection without [checkprogsize] error AND a working debugger on simavr!
Only remaining open question: why does [env:debug] neither affect Debug nor Inspect by default and how do I change that?