[PATCH] D55298: [llvm-readelf] Add -e/--headers support to readobj/elf

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 6 02:30:42 PST 2018


jhenderson added a comment.

> The output from llvm-readobj vs. llvm-readelf is almost always different and that is either by design or accident. Are you suggesting syncing the output between readobj and readelf for this case, basically setting, --elf-output-style=GNU when --headers is specified. Is that what you want?

We shouldn't sync the output between llvm-readobj and llvm-readelf, although both should produce the right set of headers when requested. For llvm-readelf, we should match what GNU readelf does. llvm-readobj does not need to match this.

The test should test the following:

- For llvm-readelf:
  - That the correct set of headers are dumped when specifying --headers.
  - That the -e switch produces the exact same output.
- For llvm-readobj (if desired, it could probably be argued that having both is unnecessary):
  - That the correct set of headers are dumped when specifying --headers.
  - That the -e switch produces the exact same output.

Hopefully that explains things.

P.S. Please remember to include the full context in the diff...


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D55298/new/

https://reviews.llvm.org/D55298





More information about the llvm-commits mailing list