Hi Jan,
On Mon, Sep 28, 2020 at 04:50:59PM +0200, Jan Kratochvil wrote:
To make DWZ better consumable it needs to have the partial units
separately
parseable. That way they can be shared at IR level and not just at DWARF
level
That means:
* DW_TAG_partial_unit should have DW_AT_language.
* DW_TAG_partial_unit must contain only types (struct/class).
Currently they contain for example also static constant variables but when
you parse such independent DW_TAG_partial_unit into which dictionary you
will register such variable? That makes no sense.
You might want to look at the experiments to do something like that
from Tom de Vries:
https://sourceware.org/pipermail/dwz/2020q1/000579.html
https://sourceware.org/pipermail/dwz/2020q1/000568.html
It is all about engineering effort. I agree if the support of DWZ
was trivial (or there were unlimited engineering resources) then DWZ
is really better than -fdebug-types-section (except it would need a
DWZ tool with less bugs and better coding practices). But reality
shows the DWZ support is not trivial engineering resources for
Fedora are very limited and so we have to decide whether the serious
effort to support DWZ is better spent on DWZ or on making the
debuggers better/really usable.
Hacking on dwz and supporting partial units and DWARF supplemential
files in debugger like tools isn't trivial. But it is IMHO also not
such a big effort that we have to drop everything else. Lets see if we
can work together on this.
Cheers,
Mark