aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorSimon Atanasyan <simon@atanasyan.com>2013-11-11 20:51:48 +0000
committerSimon Atanasyan <simon@atanasyan.com>2013-11-11 20:51:48 +0000
commitfe9ce427d076627beed834d5c322e61323dfd1fc (patch)
treedd38939ddb8628d8118dee27921baa95eb3b3435 /tools
parent2531651206a2d12d37ad93a6f9bc9f8762105b4e (diff)
downloadexternal_llvm-fe9ce427d076627beed834d5c322e61323dfd1fc.zip
external_llvm-fe9ce427d076627beed834d5c322e61323dfd1fc.tar.gz
external_llvm-fe9ce427d076627beed834d5c322e61323dfd1fc.tar.bz2
Add support for DT_VERxxx and DT_MIPS_xxx .dynamic section entries to the
llvm-readobj. The patch reviewed by Michael Spencer. http://llvm-reviews.chandlerc.com/D2113 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194421 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r--tools/llvm-readobj/ELFDumper.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/tools/llvm-readobj/ELFDumper.cpp b/tools/llvm-readobj/ELFDumper.cpp
index f384824..07a9083 100644
--- a/tools/llvm-readobj/ELFDumper.cpp
+++ b/tools/llvm-readobj/ELFDumper.cpp
@@ -683,6 +683,16 @@ static const char *getTypeString(uint64_t Type) {
LLVM_READOBJ_TYPE_CASE(SYMENT);
LLVM_READOBJ_TYPE_CASE(SYMTAB);
LLVM_READOBJ_TYPE_CASE(TEXTREL);
+ LLVM_READOBJ_TYPE_CASE(VERNEED);
+ LLVM_READOBJ_TYPE_CASE(VERNEEDNUM);
+ LLVM_READOBJ_TYPE_CASE(VERSYM);
+ LLVM_READOBJ_TYPE_CASE(MIPS_RLD_VERSION);
+ LLVM_READOBJ_TYPE_CASE(MIPS_FLAGS);
+ LLVM_READOBJ_TYPE_CASE(MIPS_BASE_ADDRESS);
+ LLVM_READOBJ_TYPE_CASE(MIPS_LOCAL_GOTNO);
+ LLVM_READOBJ_TYPE_CASE(MIPS_SYMTABNO);
+ LLVM_READOBJ_TYPE_CASE(MIPS_UNREFEXTNO);
+ LLVM_READOBJ_TYPE_CASE(MIPS_GOTSYM);
default: return "unknown";
}
}
@@ -715,9 +725,21 @@ static void printValue(const ELFFile<ELFT> *O, uint64_t Type, uint64_t Value,
case DT_FINI_ARRAY:
case DT_PREINIT_ARRAY:
case DT_DEBUG:
+ case DT_VERNEED:
+ case DT_VERSYM:
case DT_NULL:
+ case DT_MIPS_FLAGS:
+ case DT_MIPS_BASE_ADDRESS:
+ case DT_MIPS_GOTSYM:
OS << format("0x%" PRIX64, Value);
break;
+ case DT_VERNEEDNUM:
+ case DT_MIPS_RLD_VERSION:
+ case DT_MIPS_LOCAL_GOTNO:
+ case DT_MIPS_SYMTABNO:
+ case DT_MIPS_UNREFEXTNO:
+ OS << Value;
+ break;
case DT_PLTRELSZ:
case DT_RELASZ:
case DT_RELAENT: