This is an archive of the discontinued LLVM Phabricator instance.

[yaml2obj] - Simplify implementation. NFCI.
ClosedPublic

Authored by grimar on Feb 20 2019, 5:10 AM.

Details

Summary

Knowing about how types are declared for 32/64 bit platforms:
https://github.com/llvm-mirror/llvm/blob/master/include/llvm/BinaryFormat/ELF.h#L28

it is possible to simplify code that writes a binary a bit.
The patch does that.

Diff Detail

Repository
rL LLVM

Event Timeline

grimar created this revision.Feb 20 2019, 5:10 AM
jhenderson accepted this revision.Feb 20 2019, 5:45 AM

LGTM.

tools/yaml2obj/yaml2elf.cpp
580 ↗(On Diff #187550)

I'd rename this from V to Version, so that it's a little easier to understand.

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