diff options
| author | Evgeniy Stepanov <eugeni.stepanov@gmail.com> | 2013-07-30 09:01:18 +0000 |
|---|---|---|
| committer | Evgeniy Stepanov <eugeni.stepanov@gmail.com> | 2013-07-30 09:01:18 +0000 |
| commit | f3e218a02127420a49ba0f0712e6a25a235fd9be (patch) | |
| tree | 06fe680fc43e6d83fdd523c08883a917721d1396 | |
| parent | 573ba3499ea4a18838e0d020483d927cc3146580 (diff) | |
| download | bcm5719-llvm-f3e218a02127420a49ba0f0712e6a25a235fd9be.tar.gz bcm5719-llvm-f3e218a02127420a49ba0f0712e6a25a235fd9be.zip | |
[asan] Raise thread stack size limit.
It's a sanity check, mostly, and we've seen threads with >256Mb stack.
llvm-svn: 187408
| -rw-r--r-- | compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cc b/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cc index a00a8e21b5b..2f9b68569cc 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cc +++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cc @@ -29,7 +29,7 @@ namespace __sanitizer { void GetThreadStackTopAndBottom(bool at_initialization, uptr *stack_top, uptr *stack_bottom) { - static const uptr kMaxThreadStackSize = 256 * (1 << 20); // 256M + static const uptr kMaxThreadStackSize = 1 << 30; // 1Gb CHECK(stack_top); CHECK(stack_bottom); if (at_initialization) { @@ -70,9 +70,9 @@ void GetThreadStackTopAndBottom(bool at_initialization, uptr *stack_top, pthread_attr_getstack(&attr, &stackaddr, (size_t*)&stacksize); pthread_attr_destroy(&attr); + CHECK_LE(stacksize, kMaxThreadStackSize); // Sanity check. *stack_top = (uptr)stackaddr + stacksize; *stack_bottom = (uptr)stackaddr; - CHECK(stacksize < kMaxThreadStackSize); // Sanity check. } // Does not compile for Go because dlsym() requires -ldl |

