diff options
author | Chris Lattner <sabre@nondot.org> | 2004-02-19 20:32:39 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-02-19 20:32:39 +0000 |
commit | 364d1203e7adaededf3c01f58bd968ee61f4a316 (patch) | |
tree | caeb85f613a14b74669c85428fee9349bdef8256 /tools/llvm-extract | |
parent | f73b4ca7f9c5e4a19c3fba9fa0280768b4c64891 (diff) | |
download | external_llvm-364d1203e7adaededf3c01f58bd968ee61f4a316.zip external_llvm-364d1203e7adaededf3c01f58bd968ee61f4a316.tar.gz external_llvm-364d1203e7adaededf3c01f58bd968ee61f4a316.tar.bz2 |
Make sure to print a stack trace whenever an error signal is delivered to
the tool.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11633 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-extract')
-rw-r--r-- | tools/llvm-extract/llvm-extract.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/llvm-extract/llvm-extract.cpp b/tools/llvm-extract/llvm-extract.cpp index 9c03f85..b91020d 100644 --- a/tools/llvm-extract/llvm-extract.cpp +++ b/tools/llvm-extract/llvm-extract.cpp @@ -19,6 +19,7 @@ #include "llvm/Transforms/IPO.h" #include "llvm/Target/TargetData.h" #include "Support/CommandLine.h" +#include "Support/Signals.h" #include <memory> #include <fstream> using namespace llvm; @@ -42,6 +43,7 @@ ExtractFunc("func", cl::desc("Specify function to extract"), cl::init("main"), int main(int argc, char **argv) { cl::ParseCommandLineOptions(argc, argv, " llvm extractor\n"); + PrintStackTraceOnErrorSignal(); std::auto_ptr<Module> M(ParseBytecodeFile(InputFilename)); if (M.get() == 0) { |