is there an optimization level that will do no, nada, none "code packing" and STILL overlay variables. it sems that after some release when opt lev 2 became required for variable overlay it is impossible to debug without having to do "strange things" to breakpoint one of 2 similar routines. Erik
I will make a small demo next week, I am very busy this week. Erik
... waiting for small demo ...
... waiting for small demo ... sorry it took so long, I decided to post when I saw it and kinds forgot Erik
175 2 176 2 case J17S_XMUW: // E1 12 // waiting for serial interrupt 177 2 break; // this would be normal 178 2 179 2 case J17S_XMCW: // E1 12 waiting for serial interrupt after cksm xmit 180 2 break; // this would be normal 181 2 182 2 default: 183 2 jI1crash (); 184 2 break; 185 2 } ; SOURCE LINE # 176 ; SOURCE LINE # 177 ; SOURCE LINE # 179 ; SOURCE LINE # 180 ; SOURCE LINE # 182 005C ?C0026: ; SOURCE LINE # 183 005C 120000 R LCALL jI1crash ; SOURCE LINE # 184 ; SOURCE LINE # 185 ; SOURCE LINE # 189 005F ?C0017:
That example is really a little too terse to be useful. But let's see --- so you actually insist that the compiler should generate separate code for each of those two 'break' statements, so you can put a breakpoint on each of them separately? Looks like you're asking for wilful code bloat rather than absence of code packing. A case consisting of nothing but a 'break;' statement is arguably not even code, so 'code packing' doesn't really apply to what happens with it.
the issue here is that vyou can not set a breakpoint on a certain condition Erik
"the issue here is that you can not set a breakpoint on a certain condition" The problem is that you have no code on these conditions - and you can't set a breakpoint on nothing! The compiler isn't optimising-away your code; there is no code there to start with! Can't you use a data breakpoint?