diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2011-08-04 15:10:35 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2011-08-04 15:10:35 +0000 |
commit | d7c278326f333f41d8ec8d19f817a117e3f11190 (patch) | |
tree | 66d6da9391a9eb4e1e637ffa1d18c645742f3182 /test/Scripts/elf-dump | |
parent | a83f8ef9b4d727011ee43743810ef1f6ec12bb81 (diff) | |
download | external_llvm-d7c278326f333f41d8ec8d19f817a117e3f11190.zip external_llvm-d7c278326f333f41d8ec8d19f817a117e3f11190.tar.gz external_llvm-d7c278326f333f41d8ec8d19f817a117e3f11190.tar.bz2 |
Print st_bind with the correct number of bits.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136874 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Scripts/elf-dump')
-rwxr-xr-x | test/Scripts/elf-dump | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/Scripts/elf-dump b/test/Scripts/elf-dump index 33581f4..a94079c 100755 --- a/test/Scripts/elf-dump +++ b/test/Scripts/elf-dump @@ -104,8 +104,10 @@ def dumpSymtab(f, section, strtab): print " ('st_value', %s)" % common_dump.HexDump(f.read32()) print " ('st_size', %s)" % common_dump.HexDump(f.read32()) st_info = f.read8() - print " ('st_bind', %s)" % common_dump.HexDump((st_info >> 4)) - print " ('st_type', %s)" % common_dump.HexDump((st_info & 0xf)) + st_bind = (st_info >> 4, 4) + st_type = (st_info & 0xf, 4) + print " ('st_bind', %s)" % common_dump.HexDump(st_bind[0], st_bind[1]) + print " ('st_type', %s)" % common_dump.HexDump(st_type[0], 32) print " ('st_other', %s)" % common_dump.HexDump(f.read8()) print " ('st_shndx', %s)" % common_dump.HexDump(f.read16()) if f.is64Bit: |