This is an archive of the discontinued LLVM Phabricator instance.

[DWARFLinker][DWARFv5] Add support for .debug_line_str table.
ClosedPublic

Authored by avl on May 15 2023, 3:19 AM.

Details

Summary

This patch adds support for DWARFv5 .debug_line_str table.
It replaces code generating line table. Instead of copying original
table and patching certain places this patch implements full line table
generation.

Diff Detail

Event Timeline

avl created this revision.May 15 2023, 3:19 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 15 2023, 3:19 AM
avl requested review of this revision.May 15 2023, 3:19 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 15 2023, 3:19 AM
JDevlieghere accepted this revision.May 15 2023, 2:08 PM

LGTM. I left some nits inline. You also have a few places where you use the names from the DWARF standard (e.g. directory_entry_format_count) while in other places you use the name of the variable in the Prologue class (e.g. SegSelectorSize instead of segment_selector_size). It would be nice to consistently use the ones from the spec to make cross referencing easier.

llvm/include/llvm/DWARFLinker/DWARFLinker.h
751
llvm/include/llvm/DWARFLinker/DWARFStreamer.h
233–254
llvm/lib/DWARFLinker/DWARFStreamer.cpp
665

spurious newline

672

Any reason you use P.FormParams.Version and not P.getVersion()?

This revision is now accepted and ready to land.May 15 2023, 2:08 PM
avl added a comment.May 16 2023, 7:27 AM

Thank you for the review!

This revision was landed with ongoing or failed builds.May 16 2023, 8:00 AM
This revision was automatically updated to reflect the committed changes.