This is an archive of the discontinued LLVM Phabricator instance.

Make dw_tag_t a llvm::dwarf::Tag
ClosedPublic

Authored by JDevlieghere on Sep 24 2019, 7:02 PM.

Details

Summary

When talking to Shafik about D67994, we discovered that dw_tag_t is a typedef for uint16_t. I believe it would be better to typedef it to llvm::dwarf::Tag instead, so we can use the full power of the DWARF utilities in LLVM without having to do the cast. With this approach, we only have to do the cast when reading the ULEB value.

Diff Detail

Repository
rL LLVM

Event Timeline

JDevlieghere created this revision.Sep 24 2019, 7:02 PM
Herald added a project: Restricted Project. · View Herald TranscriptSep 24 2019, 7:02 PM
Herald added a subscriber: aprantl. · View Herald Transcript
labath accepted this revision.Sep 25 2019, 1:53 AM

Makes sense to me.

This revision is now accepted and ready to land.Sep 25 2019, 1:53 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptSep 25 2019, 9:02 AM
aprantl added inline comments.Sep 25 2019, 9:24 AM
lldb/trunk/include/lldb/Core/dwarf.h
23

so should this be llvm::dwarf::Attribute?

24

llvm::dwarf::Form?

Thanks for doing this! I spent a bunch of time trying to understand that relationship yesterday.