llvm-project/llvm/test/tools/llvm-objdump
Kevin Enderby a8d256cb36 Add the rest of the error checking for Mach-O dyld compact bind entry errors
and test cases for each of the error checks.

To do this more plumbing was needed so that the segment indexes and
segment offsets can be checked.  Basically what was done was the SegInfo
from llvm-objdump’s MachODump.cpp was moved into libObject for Mach-O
objects as BindRebaseSegInfo and it is only created when an iterator for
bind or rebase entries are created.

This commit really only adds the error checking and test cases for the
bind table entires and the checking for the lazy bind and weak bind entries
are still to be fully done as well as the rebase entires.  Though some of
the plumbing for those are added with this commit.  Those other error
checks and test cases will be added in follow on commits.

Note, the two llvm_unreachable() calls should now actually be unreachable
with the error checks in place and would take a logic bug in the error
checking code to be reached if the segment indexes and segment
offsets are used from a checked bind entry.  Comments have been added
to the methods that require the arguments to have been checked
prior to calling.

llvm-svn: 298292
2017-03-20 19:46:55 +00:00
..
AArch64 Yet another fix llvm-objdump so it picks a good CPU based for Mach-O files, 2017-02-10 19:27:10 +00:00
AMDGPU Fix source-lines test on Windows. 2017-03-07 21:53:21 +00:00
ARM Fix llvm-objdump so it picks a good CPU based for Mach-O files 2017-01-24 23:41:04 +00:00
Hexagon [IR] Remove the DIExpression field from DIGlobalVariable. 2016-12-20 02:09:43 +00:00
Inputs Add the rest of the error checking for Mach-O dyld compact bind entry errors 2017-03-20 19:46:55 +00:00
Mips [mips] Drop unneeded REQUIRES line in test. NFCI 2017-03-01 14:31:09 +00:00
X86 Add the rest of the error checking for Mach-O dyld compact bind entry errors 2017-03-20 19:46:55 +00:00
coff-file.test
coff-import-library.test llvm-objdump: add coff import library symbol listing support 2016-08-18 16:39:19 +00:00
coff-large-bss.test
coff-many-relocs.test
coff-non-null-terminated-file.test
coff-private-headers.test
common-symbol-elf.test
eh_frame-arm64.test
eh_frame-mipsel.test
eh_frame_zero_cie.test
hex-relocation-addr.test
invalid-input.test
macho-LLVM-bundle.test Add the printing the Mach-O (__LLVM,__bundle) xar archive file section "verbosely" 2016-05-23 21:34:12 +00:00
macho-bad-bind.test Add the rest of the error checking for Mach-O dyld compact bind entry errors 2017-03-20 19:46:55 +00:00
macho-bad-ordinal.test Actually add error handling to unpacking the dyld compact bind and 2017-02-28 21:47:07 +00:00
macho-bind.test
macho-bind2.test
macho-compact-unwind-i386.test
macho-compact-unwind-x86_64.test
macho-exports-trie.test
macho-lazy-bind.test
macho-objc-meta-data.test Add a test case for the crash fixed with r267037. David Blaikie said it would be nice to have! 2016-04-27 20:37:06 +00:00
macho-rebase.test
macho-sections.test Fix bugs in llvm-objdump printing the last word for -section in non i386 and x86 files. 2016-04-27 23:43:00 +00:00
macho-unwind-info-arm64.test
macho-unwind-info-no-relocs.test
macho-unwind-info-x86_64.test
macho-weak-bind.test
malformed-archives.test llvm-objdump: Make some error messages more consistent 2016-10-26 22:37:52 +00:00
malformed-macho.test Change the llvm-obdump(1) behavior with the -macho flag and inappropriate file types. 2017-01-30 20:53:17 +00:00
malformed-unwind-x86_64.test llvm-objdump: deal with unexpected object files more gracefully. 2016-11-15 20:26:01 +00:00
proc-specific-section-elf.test
section-filter.test
wasm.txt [WebAssembly] Update llvm-objdump tests for the new wasm version number. 2017-02-22 20:24:16 +00:00
win64-unwind-data.test