[PATCH] D84330: [llvm-readelf] - Simplify the implementation of getSectionTypeString() helper. NFCI.

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 23 00:26:36 PDT 2020


jhenderson accepted this revision.
jhenderson added a comment.
This revision is now accepted and ready to land.

LGTM.



================
Comment at: llvm/tools/llvm-readobj/ELFDumper.cpp:3784-3787
+  // The SHT_ANDROID_RELR is special, all other SHT_ANDROID_* types are handled
+  // in the common block below.
+  if (Name == "SHT_ANDROID_RELR")
     return "RELR";
----------------
FWIW, I think this clause is a bad design in the original version - a user when dumping the section headers will not be able to distinguish between SHT_RELR and SHT_ANDROID_RELR. They might be identical internally, but the sh_type value is different.

We shouldn't fix it in this patch, but it might be worth reaching out to the original people to implement it to bring this up. What do you think?


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

https://reviews.llvm.org/D84330





More information about the llvm-commits mailing list