summaryrefslogtreecommitdiffstats
path: root/lldb/include/lldb/API
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2019-11-19 17:28:46 -0800
committerJonas Devlieghere <jonas@devlieghere.com>2019-11-20 13:14:16 -0800
commitc8dfe907299e16aeb17175cb0896c17043fc7c81 (patch)
tree85aa1fcf033d71c0243f3efec47e593a5ba0818e /lldb/include/lldb/API
parent824b25fc02dc4544adae55e6451d355f4c6d7055 (diff)
downloadbcm5719-llvm-c8dfe907299e16aeb17175cb0896c17043fc7c81.tar.gz
bcm5719-llvm-c8dfe907299e16aeb17175cb0896c17043fc7c81.zip
[Reproducer] Generate LLDB reproducer on crash
This patch hooks the reproducer infrastructure with the signal handlers. When lldb crashes with reproducers capture enabled, it will now generate the reproducer and print a short message the standard out. This doesn't affect the pretty stack traces, which are still printed before. This patch also introduces a new reproducer sub-command that intentionally raises a given signal to test the reproducer signal handling. Currently the signal handler is doing too much work. Instead of copying over files into the reproducers in the signal handler, we should re-invoke ourselves with a special command line flag that looks at the VFS mapping and performs the copy. This is a NO-OP when reproducers are disabled. Differential revision: https://reviews.llvm.org/D70474
Diffstat (limited to 'lldb/include/lldb/API')
-rw-r--r--lldb/include/lldb/API/SBReproducer.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/lldb/include/lldb/API/SBReproducer.h b/lldb/include/lldb/API/SBReproducer.h
index 0f1739d0c5b..93e567607aa 100644
--- a/lldb/include/lldb/API/SBReproducer.h
+++ b/lldb/include/lldb/API/SBReproducer.h
@@ -21,6 +21,8 @@ public:
static const char *Capture();
static const char *Capture(const char *path);
static const char *Replay(const char *path);
+ static const char *GetPath();
+ static bool Generate();
};
} // namespace lldb
OpenPOWER on IntegriCloud