[llvm-objcopy] Support the rest of the ELF formats
ClosedPublic

Authored by jakehehrlich on Mon, Nov 13, 1:27 PM.

Details

Summary

We haven't been supporting anything but ELF64LE since the start. Luckily this was always accounted for and the change is pretty trivial. B35281 requests this change for ELF32LE. This change adds support for ELF32LE, ELF64BE, and ELF32BE with all supported features that already existed for ELF64LE.

Diff Detail

Repository
rL LLVM
jakehehrlich created this revision.Mon, Nov 13, 1:27 PM
davide added a subscriber: davide.Mon, Nov 13, 6:12 PM
davide added inline comments.
tools/llvm-objcopy/llvm-objcopy.cpp
213 ↗(On Diff #122716)

auto *

Replaced explicit types with auto as recommended. Thanks Davide!

jhenderson accepted this revision.Tue, Nov 14, 2:52 AM

LGTM.

I don't see any sensible way of doing this, but it would be really nice if every single one of our test cases could be run for all 4 forms, as I believe the same behaviour should be present in all of them. The test coverage for this change though is good enough though. Thanks.

This revision is now accepted and ready to land.Tue, Nov 14, 2:52 AM
This revision was automatically updated to reflect the committed changes.