1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00
llvm-mirror/tools
Kevin Enderby 92582f2b18 Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message.
Produce another specific error message for a malformed Mach-O file when a symbol’s
string index is past the end of the string table.  The existing test case in test/Object/macho-invalid.test
for macho-invalid-symbol-name-past-eof now reports the error with the message indicating
that a symbol at a specific index has a bad sting index and that bad string index value.
 
Again converting interfaces to Expected<> from ErrorOr<> does involve
touching a number of places. Where the existing code reported the error with a
string message or an error code it was converted to do the same.  There is some
code for this that could be factored into a routine but I would like to leave that for
the code owners post-commit to do as they want for handling an llvm::Error.  An
example of how this could be done is shown in the diff in
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h which had a Check() routine
already for std::error_code so I added one like it for llvm::Error .

Also there some were bugs in the existing code that did not deal with the
old ErrorOr<> return values.  So now with Expected<> since they must be
checked and the error handled, I added a TODO and a comment:
“// TODO: Actually report errors helpfully” and a call something like
consumeError(NameOrErr.takeError()) so the buggy code will not crash
since needed to deal with the Error.

Note there fixes needed to lld that goes along with this that I will commit right after this.
So expect lld not to built after this commit and before the next one.

llvm-svn: 266919
2016-04-20 21:24:34 +00:00
..
bugpoint Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
bugpoint-passes Remove autoconf support 2016-01-26 21:29:08 +00:00
dsymutil Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
gold Re-enable "[gold-plugin] Disable name for values other than GlobalValue" 2016-04-20 15:16:57 +00:00
llc Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
lli [Orc] Re-commit r266581 with fixes for MSVC, and format cleanups. 2016-04-18 19:55:43 +00:00
llvm-ar Fix formatting and wording of llvm-ranlib error message. NFC. 2016-04-08 00:02:14 +00:00
llvm-as Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-as-fuzzer Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-bcanalyzer [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
llvm-c-test [llvm-c] Expose LLVMContextGetDiagnostic{Handler,Context} 2016-04-08 09:19:02 +00:00
llvm-config llvm-config: fix --libs on Linux 2016-03-14 21:39:58 +00:00
llvm-cov Thread Expected<...> up from createMachOObjectFile() to allow llvm-objdump to produce a real error message 2016-04-06 22:14:09 +00:00
llvm-cxxdump Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
llvm-diff [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
llvm-dis Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-dwarfdump [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
llvm-dwp [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
llvm-extract Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-go Remove autoconf support 2016-01-26 21:29:08 +00:00
llvm-jitlistener Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-link IR: Rename API for enabling ODR uniquing of DITypes, NFC 2016-04-19 04:55:25 +00:00
llvm-lto llvm-lto: run the module verifier when doing IR level work 2016-04-20 01:04:26 +00:00
llvm-mc MC: Don't access the filesystem in MCContext's constructor 2016-03-22 22:24:29 +00:00
llvm-mc-fuzzer [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
llvm-mcmarkup Remove autoconf support 2016-01-26 21:29:08 +00:00
llvm-nm Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
llvm-objdump Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
llvm-pdbdump [llvm-pdbdump] Print a better error message when PDB loading fails. 2016-04-19 17:36:58 +00:00
llvm-profdata Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-readobj Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
llvm-rtdyld Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
llvm-shlib llvm-shlib: Remove the option to override __cxa_atexit 2016-03-14 21:54:45 +00:00
llvm-size Thread Expected<...> up from createMachOObjectFile() to allow llvm-objdump to produce a real error message 2016-04-06 22:14:09 +00:00
llvm-split Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
llvm-stress [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
llvm-symbolizer Remove autoconf support 2016-01-26 21:29:08 +00:00
lto LTO: Use a common LibLTOCodeGenerator::init, NFC 2016-04-16 22:25:36 +00:00
msbuild MSBuild integration: fix the loop in install.bat 2014-09-30 22:30:06 +00:00
obj2yaml Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
opt Enable ODR uniquing of DITypes in more places 2016-04-19 15:48:30 +00:00
sancov Thread Expected<...> up from libObject’s getName() for symbols to allow llvm-objdump to produce a good error message. 2016-04-20 21:24:34 +00:00
sanstats Revert "Fix Clang-tidy modernize-deprecated-headers warnings in remaining files; other minor fixes." 2016-04-05 20:45:04 +00:00
verify-uselistorder Remove every uses of getGlobalContext() in LLVM (but the C API) 2016-04-14 21:59:01 +00:00
xcode-toolchain [CMake] [Darwin] Add support for generating Xcode-compatible toolchains that xcodebuild and xcrun can search 2015-10-15 20:09:01 +00:00
yaml2obj [NFC] Header cleanup 2016-04-18 09:17:29 +00:00
CMakeLists.txt [CMake] Add the gold plugin before clang 2016-02-26 21:07:04 +00:00
LLVMBuild.txt llvm-dwp: Initial layout 2015-12-01 00:48:34 +00:00