This is an archive of the discontinued LLVM Phabricator instance.

[yaml2obj]Allow number for ELF symbol type
ClosedPublic

Authored by jhenderson on Feb 6 2019, 8:17 AM.

Details

Summary

yaml2obj previously only recognised standard STT_* names, and didn't allow arbitrary numbers. This change allows the user to specify a number for the type instead. It also adds a test to verify the existing behaviour for obj2yaml for unkown symbol types.

Diff Detail

Repository
rL LLVM

Event Timeline

jhenderson created this revision.Feb 6 2019, 8:17 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 6 2019, 8:17 AM
grimar accepted this revision.Feb 6 2019, 8:37 AM

LGTM.

This revision is now accepted and ready to land.Feb 6 2019, 8:37 AM
grimar added inline comments.Feb 6 2019, 8:38 AM
test/tools/yaml2obj/symbol-type.yaml
5

Oh, maybe use CHECK-NEXT?

jhenderson marked an inline comment as done.Feb 6 2019, 8:42 AM
jhenderson added inline comments.
test/tools/yaml2obj/symbol-type.yaml
5

These aren't on adjacent lines, so CHECK-NEXT would have to check things like the value line etc in between.

grimar added inline comments.Feb 6 2019, 8:43 AM
test/tools/yaml2obj/symbol-type.yaml
5

OK.

This revision was automatically updated to reflect the committed changes.