[PATCH] D105055: [llvm-readobj] Make -s and -t match llvm-readelf

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 28 12:39:42 PDT 2021


MaskRay created this revision.
MaskRay added reviewers: jhenderson, rupprecht.
Herald added a subscriber: emaste.
MaskRay requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

llvm-readobj is an internal testing tool for binary formats. Its output and
command line options do not need to be stable. It isn't supposed to be part of a
build process.

llvm-readelf was created as a user-facing utility and its interface intends to
be compatible with GNU readelf (unless there are good reasons not to).

The two tools have mostly compatible options. -s and -t are noticeable
exceptions due to history. I think keeping the inconsistency overweighs the
little history-compatible benefit and hinders transition from cl::opt to
OptTable, so let's change it.

I have fixed test/tools tests and will be happy to fix CodeGen/MC tests
when we decide to do this.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D105055

Files:
  llvm/docs/CommandGuide/llvm-readobj.rst
  llvm/test/tools/llvm-readobj/ELF/merged.test
  llvm/test/tools/llvm-readobj/ELF/sections.test
  llvm/test/tools/llvm-readobj/ELF/symbols.test
  llvm/test/tools/llvm-readobj/basic.test
  llvm/test/tools/yaml2obj/ELF/duplicate-symbol-names.yaml
  llvm/tools/llvm-readobj/llvm-readobj.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D105055.354996.patch
Type: text/x-patch
Size: 7495 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210628/14bcdfba/attachment.bin>


More information about the llvm-commits mailing list