llvm/tools/llvm-objdump
Kevin Enderby 04195353af Fix llvm-objdump when disassembling a stripped Mach-O binary with the -macho option.
It was printing out nothing in this case.

llvm-objdump tries to disassemble sections a symbol at a time.  In the case of a
fully stripped Mach-O executable the only symbol remaining in the (__TEXT,__text)
section is the special linker defined symbol __mh_execute_header . This
symbol is special in that while it is N_SECT symbol in the (__TEXT,__text)
its address is before the start of the (__TEXT,__text).  It’s address is the
start of the __TEXT segment which is where the mach header is statically
linked. So the code in DisassembleMachO() needs to deal with this case specially.

rdar://26778273


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272837 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:14:01 +00:00
..
CMakeLists.txt [CMake] Restrict libxar linkage to just llvm-objdump 2016-05-26 16:32:40 +00:00
COFFDump.cpp llvm-objdump: support dumping AUX records for weak externals 2016-05-26 01:45:12 +00:00
ELFDump.cpp
llvm-objdump.cpp Search for llvm-symbolizer binary in the same directory as argv[0], before 2016-06-09 00:53:21 +00:00
llvm-objdump.h Change llvm-objdump, llvm-nm and llvm-size when reporting an object file error 2016-05-31 20:35:34 +00:00
LLVMBuild.txt
MachODump.cpp Fix llvm-objdump when disassembling a stripped Mach-O binary with the -macho option. 2016-06-15 21:14:01 +00:00