summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-readobj/Error.cpp
diff options
context:
space:
mode:
authorKevin Enderby <enderby@apple.com>2016-10-19 23:44:34 +0000
committerKevin Enderby <enderby@apple.com>2016-10-19 23:44:34 +0000
commit210030ba95df715ec32d1dd2918f2ef8206817f7 (patch)
tree7b8dfafbe3c6164e325dcd70e0110c007c4bd55a /llvm/tools/llvm-readobj/Error.cpp
parent6432d45f7b97e37535e62ab3b505d327c99ed74c (diff)
downloadbcm5719-llvm-210030ba95df715ec32d1dd2918f2ef8206817f7.tar.gz
bcm5719-llvm-210030ba95df715ec32d1dd2918f2ef8206817f7.zip
Next set of additional error checks for invalid Mach-O files for the
load commands that use the MachO::thread_command type but are not used in llvm libObject code but used in llvm tool code. This includes the LC_UNIXTHREAD and LC_THREAD load commands. A quick note about the philosophy of the error checking in libObject for Mach-O files, the idea behind the checking is that we never will return a Mach-O file out of libObject that contains unknown things in the load commands. To do this the 32-bit ARM and PPC general tread states needed to be defined as two test case binaries contained them. If other thread states for other CPUs need to be added we will do that as needed. Going forward the LC_MAIN load command is used to set the entry point in Mach-O executables these days instead of an LC_UNIXTHREAD as was done in the past. So today only in core files are LC_THREAD load commands and thread states usually found. Other thread states have not yet been defined in include/Support/MachO.h at this time. But that can be added as needed with their corresponding checking also added. llvm-svn: 284668
Diffstat (limited to 'llvm/tools/llvm-readobj/Error.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud