Remove the maximum stack cleanup size check. With ulimit -s unlimited
main thread stack can be very large, but we don't really have a choice
other than cleaning all of it. It should be reasonably fast - hwasan
cleans large shadow ranges with a single madvise call.
This change fixes check-hwasan after ulimit -s unlimited.
llvm-svn: 355137
CHECK(t);
uptr top = t->stack_top();
uptr bottom = t->stack_bottom();
- static const uptr kMaxExpectedCleanupSize = 64 << 20; // 64M
- if (top == 0 || bottom == 0 || sp < bottom || sp >= top ||
- sp - bottom > kMaxExpectedCleanupSize) {
+ if (top == 0 || bottom == 0 || sp < bottom || sp >= top) {
Report(
"WARNING: HWASan is ignoring requested __hwasan_handle_vfork: "
"stack top: %zx; current %zx; bottom: %zx \n"