[PATCH] D54124: [llvm-readelf] Make llvm-readelf more compatible with GNU readelf.

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 7 03:56:33 PST 2018


jhenderson added a comment.

Please also add the following aliases:

- --syms is also a GNU readelf option as an alias for --symbols.
- --dyn-syms is the GNU readelf version of --dyn-symbols.
- --histogram is the GNU readelf long-form of -I/--elf-hash-histogram.

I think those are the various missing aliases for supported features, on top of the ones you're proposing adding.



================
Comment at: tools/llvm-readobj/llvm-readobj.cpp:57
+              "--sections, --symbols, --relocations, --dynamic-table, --notes, "
+              "--version-info --unwind, --section-groups and --histogram."));
+  cl::alias AllShort("a", cl::desc("Alias for --all"), cl::aliasopt(All));
----------------
Missing comma between --version-info and --unwind. Also --histogram isn't a thing in llvm-readelf, as far as I can tell (but you should probably add it in this patch).


================
Comment at: tools/llvm-readobj/llvm-readobj.cpp:617-619
+  static cl::alias SectionHeadersAlias("section-headers",
+                                       cl::desc("Alias for --sections"),
+                                       cl::aliasopt(opts::Sections));
----------------
I actually think --section-headers is clearer than --sections...


Repository:
  rL LLVM

https://reviews.llvm.org/D54124





More information about the llvm-commits mailing list