[compiler-rt] r184190 - [asan] fix a rare failure in fast unwinder, found by asan/clang bootstrap
Kostya Serebryany
kcc at google.com
Tue Jun 18 07:47:40 PDT 2013
Author: kcc
Date: Tue Jun 18 09:47:40 2013
New Revision: 184190
URL: http://llvm.org/viewvc/llvm-project?rev=184190&view=rev
Log:
[asan] fix a rare failure in fast unwinder, found by asan/clang bootstrap
Modified:
compiler-rt/trunk/lib/sanitizer_common/sanitizer_stacktrace.cc
Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_stacktrace.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/sanitizer_stacktrace.cc?rev=184190&r1=184189&r2=184190&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_stacktrace.cc (original)
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_stacktrace.cc Tue Jun 18 09:47:40 2013
@@ -133,6 +133,7 @@ void StackTrace::FastUnwindStack(uptr pc
size = 1;
uhwptr *frame = (uhwptr *)bp;
uhwptr *prev_frame = frame - 1;
+ if (stack_top < 4096) return; // Sanity check for stack top.
// Avoid infinite loop when frame == frame[0] by using frame > prev_frame.
while (frame > prev_frame &&
frame < (uhwptr *)stack_top - 2 &&
More information about the llvm-commits
mailing list