summaryrefslogtreecommitdiff
path: root/tools/llvm-prof
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-02-19 20:32:12 +0000
committerChris Lattner <sabre@nondot.org>2004-02-19 20:32:12 +0000
commitf73b4ca7f9c5e4a19c3fba9fa0280768b4c64891 (patch)
tree500eafc4367fd83ce3566626321727aa6746a8da /tools/llvm-prof
parent982774cbebd0280078ee5321ed638a266e79a597 (diff)
downloadllvm-f73b4ca7f9c5e4a19c3fba9fa0280768b4c64891.tar.gz
llvm-f73b4ca7f9c5e4a19c3fba9fa0280768b4c64891.tar.bz2
llvm-f73b4ca7f9c5e4a19c3fba9fa0280768b4c64891.tar.xz
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@11632 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-prof')
-rw-r--r--tools/llvm-prof/llvm-prof.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/llvm-prof/llvm-prof.cpp b/tools/llvm-prof/llvm-prof.cpp
index 3c9c3906ff..2a7789dcd5 100644
--- a/tools/llvm-prof/llvm-prof.cpp
+++ b/tools/llvm-prof/llvm-prof.cpp
@@ -18,6 +18,7 @@
#include "llvm/Analysis/ProfileInfoLoader.h"
#include "llvm/Bytecode/Reader.h"
#include "Support/CommandLine.h"
+#include "Support/Signals.h"
#include <cstdio>
#include <map>
#include <set>
@@ -80,6 +81,7 @@ namespace {
int main(int argc, char **argv) {
cl::ParseCommandLineOptions(argc, argv, " llvm profile dump decoder\n");
+ PrintStackTraceOnErrorSignal();
// Read in the bytecode file...
std::string ErrorMessage;