-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support skeleton and split compilation units #521
Conversation
Does your application handle Either way, this is going to be a large breaking change, so I'll do a release first. |
No, I don't handle |
In order to handle type units in DWARF 5, type units need to be another variant in a |
I'm happy to implement it but I'm not entirely sure what you're suggesting. Do you mean to combine |
Yes. So |
…g rather than potentially silently doing the wrong thing.
Alright this is rebased on top of #523, plus a few extras now that type units are mixed in. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks!
The gist of this is that in DWARF 5 the DWO id for skeleton/split units lives in the header rather than as an attribute on the CU, so it needs to be parsed and saved somewhere. I chose not to revisit the decision to have a separate
CompilationUnitHeader
andTypeUnitHeader
, and instead replacedUnitHeader
with a trait that they both implement. What was previouslyUnitHeader
is nowCommonUnitHeader
and used in many fewer places. Finally,CompilationUnitHeader
grew aCompilationUnitType
field that tells us whether we have a conventional, skeleton, or split unit (and what the DWO id is in the latter cases).