------- Comment #2 from jdraper at super dot org  2009-04-28 18:24 -------
(In reply to comment #1)
> IIRC at -O0, variable tracking is not enabled so it only produces single
> locations.
> 

This makes sense to me as a possible explanation, but my response would be to
turn variable tracking on even at -O0. If gcc were not set up to produce
location lists at all, then the compiler would be stuck producing a location
description that would be guaranteed to be wrong at some address. But since it
has this capability, I think that it should produce correct debugging
information at every optimization level, not just for optimized code. Producing
information that is wrong unless the debugger does some contortion to adjust
the breakpoint just doesn't seem like the right decision.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39703

Reply via email to