1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00
Commit Graph

10 Commits

Author SHA1 Message Date
Daniel Dunbar
8f3d8495f5 CrashRecoveryContext: Add RunSafelyOnThread helper function.
llvm-svn: 118272
2010-11-05 07:19:09 +00:00
Daniel Dunbar
f5c3546f2b CrashRecoveryContext: Add missing return, so that the signal fires after we our
routine is off the stack. Otherwise we show up rather confusingly in the stack
trace.

llvm-svn: 116755
2010-10-18 21:55:18 +00:00
Daniel Dunbar
e88f283f80 CrashRecovery: Clear the current context on the first crash, to avoid re-entering it if the cleanup code crashes.
llvm-svn: 111309
2010-08-17 22:32:39 +00:00
Daniel Dunbar
b5312b0f26 CrashRecovery: Add CrashRecoveryContext::GetCurrent(), so clients can find the active context from anywhere.
llvm-svn: 111308
2010-08-17 22:32:37 +00:00
Daniel Dunbar
0fc35d7284 CrashRecovery: Make CrashRecoveryContext static methods thread safe.
llvm-svn: 111307
2010-08-17 22:32:34 +00:00
Daniel Dunbar
c97e760282 Fix -Wmissing-field-initializers warnings.
llvm-svn: 109872
2010-07-30 17:49:04 +00:00
Daniel Dunbar
d516b0a1bd CrashRecovery: Use ThreadLocal::erase() instead of set(0).
llvm-svn: 109752
2010-07-29 15:24:21 +00:00
Daniel Dunbar
d62252d9f8 Make sure to include config.h, to pickup LLVM_ON_WIN32.
llvm-svn: 109721
2010-07-29 01:52:04 +00:00
Daniel Dunbar
a5b23b4df1 CrashRecoveryContext: Add a simple POSIX implementation.
- This works, but won't handle crashes on stack overflow, or signals delivered
   to a thread other than the one that crashed. The latter is particular annoying
   on Darwin, because SIGABRT tends to go to the main thread.

llvm-svn: 109717
2010-07-29 01:21:47 +00:00
Daniel Dunbar
4cf25fa76a Support: Add CrashRecoveryContext helper object.
- Designed as a simple wrapper to allow clients to attempt to catch crashes
   (memory errors, assertion violations, etc.) and do some kind of recovery.

 - Currently doesn't actually attempt to catch crashes.

llvm-svn: 109586
2010-07-28 15:40:20 +00:00