Teach llvm-objdump with the -macho parser how to use the data in code table
authorKevin Enderby <enderby@apple.com>
Thu, 6 Jun 2013 17:20:50 +0000 (17:20 +0000)
committerKevin Enderby <enderby@apple.com>
Thu, 6 Jun 2013 17:20:50 +0000 (17:20 +0000)
commit54154f3bf1ae3d2dfd68cc9474cad061b3338a40
tree5ebe75661f64525d36edb04be5363c1d10e112c9
parentf2988a00843bf5ddef7c9ee8b26534a1aa8c56cf
Teach llvm-objdump with the -macho parser how to use the data in code table
from the LC_DATA_IN_CODE load command.  And when disassembling print
the data in code formatted for the kind of data it and not disassemble those
bytes.

I added the format specific functionality to the derived class MachOObjectFile
since these tables only appears in Mach-O object files. This is my first
attempt to modify the libObject stuff so if folks have better suggestions
how to fit this in or suggestions on the implementation please let me know.

rdar://11791371

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183424 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Object/MachO.h
lib/Object/MachOObjectFile.cpp
test/Object/Inputs/macho-data-in-code.macho-thumbv7 [new file with mode: 0644]
test/Object/X86/macho-data-in-code.test [new file with mode: 0644]
tools/llvm-objdump/MachODump.cpp
tools/macho-dump/macho-dump.cpp