Commit ec61097a authored by Tudor Bosman's avatar Tudor Bosman Committed by Jordan DeLong

Change exception tracer to use per-thread caching in libunwind

Summary: Because the global cache is slow and contends on locks.

Test Plan: testinproduction

Reviewed By: philipp@fb.com

FB internal diff: D1081259
parent cb394cb5
...@@ -81,6 +81,8 @@ void initialize() { ...@@ -81,6 +81,8 @@ void initialize() {
!orig_cxa_end_catch || !orig_rethrow_exception) { !orig_cxa_end_catch || !orig_rethrow_exception) {
abort(); // what else can we do? abort(); // what else can we do?
} }
initStackTrace();
} }
} // namespace } // namespace
......
...@@ -75,6 +75,11 @@ void clearStack(StackTraceStack** head); ...@@ -75,6 +75,11 @@ void clearStack(StackTraceStack** head);
*/ */
int moveTop(StackTraceStack** from, StackTraceStack** to); int moveTop(StackTraceStack** from, StackTraceStack** to);
/**
* Initialize the stack tracing code.
*/
void initStackTrace();
#ifdef __cplusplus #ifdef __cplusplus
} /* extern "C" */ } /* extern "C" */
#endif #endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment