https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102523

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
This can't be done.  -O0's main objective is fast compile time, -fvar-tracking*
is very expensive compile time.
What we want is instead a special var-tracking mode that would track only what
is necessary for -O0 where most of the variables live in memory.
In particular, one needs to track variables with register keyword (those aren't
pinned into memory), probably passing of parameters and return values in the
prologue and epilogue and probably VLA dimensions in some cases.
Note, -Og, while it does var-tracking and generally attempts to disable many
optimizations that could hurt debuggability unfortunately doesn't add
artificial uses of all vars at the end of their scope and so sometimes -O0 -g
is debuggable much better than -Og -g, sometimes the other way around.

Reply via email to