Skip to content

DWARF support for multiple line tables #2557

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

Merged
merged 22 commits into from
Jan 9, 2020
Merged

DWARF support for multiple line tables #2557

merged 22 commits into from
Jan 9, 2020

Conversation

kripken
Copy link
Member

@kripken kripken commented Dec 25, 2019

Multiple tables appear to be emitted when linking files
together. This fixes our support for that, which did not
update their size properly. This required patching the
YAML emitting code from LLVM in order to measure
the size and then emit it, as that code is apparently
not designed to handle changes in line table
contents.

Other minor fixes:

  • Set the flags for our dwarfdump command to emit
    the same as llvm-dwarfdump does with -v -all.
  • Add support for a few more opcodes,
    set_discriminator, set_basic_block, fixed_advance_pc,
    set_isa.
  • Handle a compile unit without abbreviations in the
    YAML code (again, apparently not something this
    LLVM code was intended to do).
  • Handle a compile unit with zero entries in the
    YAML code (ditto).
  • Properlty set the AddressSize - we use the
    DWARFContext in a different way than LLVM expects,
    apparently.

With this the great majority of the emscripten test
suite passes with -gforce_dwarf.

My overall impression so from the the YAML code is
that it probably isn't a long-term solution for us. Perhaps
it may end up being scaffolding, that is, we can
replace it with our own code eventually that is based
on it, and remove most of the LLVM code. Before
deciding that we should get everything working first,
and this seems like the quickest path there.

@kripken kripken requested a review from dschuff December 25, 2019 16:41
@kripken kripken merged commit 98747d9 into master Jan 9, 2020
@kripken kripken deleted the moredwarf branch January 9, 2020 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants