This is an archive of the discontinued LLVM Phabricator instance.

[lld][WebAssemlby] Fix for string merging of -dwarf-5 sections
ClosedPublic

Authored by sbc100 on Jun 1 2021, 12:52 PM.

Details

Summary

We were mistakenly treating .debug_str_offsets as a string mergable
section when it is not (it contains integers not strings). This is an
indication that we really should find a way to store flags for custom
sections.

Diff Detail

Event Timeline

sbc100 created this revision.Jun 1 2021, 12:52 PM
sbc100 requested review of this revision.Jun 1 2021, 12:52 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 1 2021, 12:52 PM
sbc100 updated this revision to Diff 349072.Jun 1 2021, 12:53 PM
  • add bug links
sbc100 updated this revision to Diff 349098.Jun 1 2021, 2:23 PM
  • add test
dschuff accepted this revision.Jun 1 2021, 2:30 PM
dschuff added inline comments.
lld/wasm/InputFiles.cpp
375

I guess there is no .debug_line_str.dwo because the .debug_line section goes into the main executable, instead of a dwo file?

This revision is now accepted and ready to land.Jun 1 2021, 2:30 PM
sbc100 added inline comments.Jun 1 2021, 2:33 PM
lld/wasm/InputFiles.cpp
375

Indeed. At least there is no such section marked in initWasmMCObjectFileInfo which is the canonical list of string merge-able sections (which is why I mention it here).

This revision was landed with ongoing or failed builds.Jun 1 2021, 2:34 PM
This revision was automatically updated to reflect the committed changes.