| @@ -385,30 +385,26 @@ bool SanitizerSetThreadName(const char * | | | @@ -385,30 +385,26 @@ bool SanitizerSetThreadName(const char * |
385 | return 0 == pthread_setname_np(pthread_self(), "%s", (void *)(intptr_t)name); | | 385 | return 0 == pthread_setname_np(pthread_self(), "%s", (void *)(intptr_t)name); |
386 | } | | 386 | } |
387 | | | 387 | |
388 | bool SanitizerGetThreadName(char *name, int max_len) { | | 388 | bool SanitizerGetThreadName(char *name, int max_len) { |
389 | return 0 == pthread_getname_np(pthread_self(), name, max_len); | | 389 | return 0 == pthread_getname_np(pthread_self(), name, max_len); |
390 | } | | 390 | } |
391 | | | 391 | |
392 | #ifndef SANITIZER_GO | | 392 | #ifndef SANITIZER_GO |
393 | //------------------------- SlowUnwindStack ----------------------------------- | | 393 | //------------------------- SlowUnwindStack ----------------------------------- |
394 | #ifdef __arm__ | | 394 | #ifdef __arm__ |
395 | #define UNWIND_STOP _URC_END_OF_STACK | | 395 | #define UNWIND_STOP _URC_END_OF_STACK |
396 | #define UNWIND_CONTINUE _URC_NO_REASON | | 396 | #define UNWIND_CONTINUE _URC_NO_REASON |
397 | #else | | 397 | #else |
398 | #ifndef _URC_NORMAL_STOP | | | |
399 | #define _URC_NORMAL_STOP 0 | | | |
400 | #define _URC_NO_REASON 1 | | | |
401 | #endif | | | |
402 | #define UNWIND_STOP _URC_NORMAL_STOP | | 398 | #define UNWIND_STOP _URC_NORMAL_STOP |
403 | #define UNWIND_CONTINUE _URC_NO_REASON | | 399 | #define UNWIND_CONTINUE _URC_NO_REASON |
404 | #endif | | 400 | #endif |
405 | | | 401 | |
406 | uptr Unwind_GetIP(struct _Unwind_Context *ctx) { | | 402 | uptr Unwind_GetIP(struct _Unwind_Context *ctx) { |
407 | #ifdef __arm__ | | 403 | #ifdef __arm__ |
408 | uptr val; | | 404 | uptr val; |
409 | _Unwind_VRS_Result res = _Unwind_VRS_Get(ctx, _UVRSC_CORE, | | 405 | _Unwind_VRS_Result res = _Unwind_VRS_Get(ctx, _UVRSC_CORE, |
410 | 15 /* r15 = PC */, _UVRSD_UINT32, &val); | | 406 | 15 /* r15 = PC */, _UVRSD_UINT32, &val); |
411 | CHECK(res == _UVRSR_OK && "_Unwind_VRS_Get failed"); | | 407 | CHECK(res == _UVRSR_OK && "_Unwind_VRS_Get failed"); |
412 | // Clear the Thumb bit. | | 408 | // Clear the Thumb bit. |
413 | return val & ~(uptr)1; | | 409 | return val & ~(uptr)1; |
414 | #else | | 410 | #else |