On 01/16/2015 08:31 AM, Jason Merrill wrote:
On 01/16/2015 05:55 AM, Richard Biener wrote:
I'd hope that in the very distant future all early DIEs would be
"created"
by the frontends (that is, dwarf2out.c wouldn't walk into
parents/siblings
so much).
Are you thinking that the front end would immediately call a debug hook
for every block, local variable and such, or just for higher level
entities?
In the very distant future, as in, when Aldy is retired and living in a
tropical island somewhere? :).
I hoped we wouldn't need the limbo list at all ... that is, parent DIEs
are always present when we create children. I think that should
work in principle if the frontends would create DIEs while parsing.
So create the function DIE as soon as we see the declaration? That
seems reasonable. Then that would be the point of early debug, not
later at EOF.
I'm certainly game to exploring this option, though I think we should be
able to get this working at EOF. The reason why I didn't take this
approach originally is because it seemed like a lot more hassle,
especially since we have to do the same thing for all other front-ends.
Note that dwarf2out forces parent DIE creation in some cases
but not in some others - it would be interesting to sort out which
parent DIEs it thinks it cannot create when we create the DIE
for a sibling. Maybe it's just poor ordering of early_global_decl
calls?
Agreed.
Regrettably, I have to agree as well. I can investigate why some DIEs
end up orphaned and report back.
Thanks.
Aldy