This is an archive of the discontinued LLVM Phabricator instance.

[dsymutil] Support and relocate base address selection entries for debug_loc
ClosedPublic

Authored by JDevlieghere on Oct 15 2019, 1:51 PM.

Details

Summary

Since r374600 clang emits base address selection entries. Currently dsymutil does not support these entries and incorrectly interprets them as location list entries.

This patch adds support for base address selection entries in dsymutil and makes sure they are relocated correctly.

Thanks to Dave for coming up with the test case!

Diff Detail

Event Timeline

JDevlieghere created this revision.Oct 15 2019, 1:51 PM
Herald added a project: Restricted Project. · View Herald TranscriptOct 15 2019, 1:51 PM

Looks right to me - but not 100% confident. Will leave it to Adrian/someone else more familiar with MachO/dsymutil/etc.

aprantl added inline comments.Oct 15 2019, 2:12 PM
llvm/tools/dsymutil/DwarfStreamer.cpp
402

BaseAddressMarker ?

aprantl accepted this revision.Oct 15 2019, 4:34 PM
This revision is now accepted and ready to land.Oct 15 2019, 4:34 PM
This revision was automatically updated to reflect the committed changes.