From 4e106f06499141ba811fff2f8231f0e01f11bee0 Mon Sep 17 00:00:00 2001 From: Brian Gaeke Date: Wed, 5 Nov 2003 01:18:49 +0000 Subject: Abort when the user program calls abort, instead of printing a funny message and calling exit(1). llvm-svn: 9716 --- llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp') diff --git a/llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp b/llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp index b2c21e1..ecf19c2 100644 --- a/llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp +++ b/llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp @@ -28,6 +28,7 @@ #include "Config/dlfcn.h" #include "Config/link.h" #include +#include #include using std::vector; @@ -142,10 +143,7 @@ GenericValue lle_X_exit(FunctionType *M, const vector &Args) { // void abort(void) GenericValue lle_X_abort(FunctionType *M, const vector &Args) { - std::cerr << "***PROGRAM ABORTED***!\n"; - GenericValue GV; - GV.IntVal = 1; - TheInterpreter->exitCalled(GV); + raise (SIGABRT); return GenericValue(); } -- cgit v1.1