This is an archive of the discontinued LLVM Phabricator instance.

[yaml2obj][obj2yaml] - Add support for the architecture specific dynamic tags.
ClosedPublic

Authored by grimar on Feb 26 2019, 3:48 AM.

Details

Summary

This allows tools to parse/dump the architecture specific tags
like DT_MIPS_*, DT_PPC64_* and DT_HEXAGON_*

Also fixes a bug in DynamicTags.def which was revealed in this patch.

Diff Detail

Event Timeline

grimar created this revision.Feb 26 2019, 3:48 AM
grimar edited the summary of this revision. (Show Details)Feb 26 2019, 3:49 AM

It's like you read my mind. I'm literally in the middle of writing an llvm-readobj test for dynamic tag dumping!

test/tools/obj2yaml/dynamic-section-arch-tags.test
112–113

I don't think you need Address or AddressAlign in this test.

115–116

I don't think you need the DT_NULL tags either?

grimar updated this revision to Diff 188343.Feb 26 2019, 4:59 AM
grimar marked 3 inline comments as done.
  • Addressed review comments.

It's like you read my mind. I'm literally in the middle of writing an llvm-readobj test for dynamic tag dumping!

No magic here this time, don't worry :) I was who introduced that "TODO" in the code which is now removed by this patch. Just finishing started.

test/tools/obj2yaml/dynamic-section-arch-tags.test
115–116

I included it because it is a mandatory field basing on ELF spec.
Though probably for this test it is not important to have it. I removed it.

This revision is now accepted and ready to land.Feb 26 2019, 5:36 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptFeb 26 2019, 6:14 AM