diff options
Diffstat (limited to 'lib/ExecutionEngine')
-rw-r--r-- | lib/ExecutionEngine/ExecutionEngine.cpp | 2 | ||||
-rw-r--r-- | lib/ExecutionEngine/JIT/JIT.cpp | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/lib/ExecutionEngine/ExecutionEngine.cpp b/lib/ExecutionEngine/ExecutionEngine.cpp index c9fd577654..4ece8b9c84 100644 --- a/lib/ExecutionEngine/ExecutionEngine.cpp +++ b/lib/ExecutionEngine/ExecutionEngine.cpp @@ -137,6 +137,8 @@ ExecutionEngine *ExecutionEngine::create(ModuleProvider *MP, } catch (...) { std::cerr << "Error creating the interpreter!\n"; } + } catch (std::string& errmsg) { + std::cerr << "Error reading the bytecode file: " << errmsg << "\n"; } catch (...) { std::cerr << "Error reading the bytecode file!\n"; } diff --git a/lib/ExecutionEngine/JIT/JIT.cpp b/lib/ExecutionEngine/JIT/JIT.cpp index 5340a19e3e..02577df3c4 100644 --- a/lib/ExecutionEngine/JIT/JIT.cpp +++ b/lib/ExecutionEngine/JIT/JIT.cpp @@ -117,6 +117,9 @@ void *JIT::getPointerToFunction(Function *F) { // Make sure we read in the function if it exists in this Module try { MP->materializeFunction(F); + } catch ( std::string& errmsg ) { + std::cerr << "Error parsing bytecode file: " << errmsg << "\n"; + abort(); } catch (...) { std::cerr << "Error parsing bytecode file!\n"; abort(); |