Index: src/execution.cc |
diff --git a/src/execution.cc b/src/execution.cc |
index 11dacfeede76912a9a0c4984eb7a2384238b5e07..f484d8d9b819af699e25786c8b66b8167441afe1 100644 |
--- a/src/execution.cc |
+++ b/src/execution.cc |
@@ -403,6 +403,7 @@ void StackGuard::ThreadLocal::Initialize() { |
if (real_climit_ == kIllegalLimit) { |
// Takes the address of the limit variable in order to find out where |
// the top of stack is right now. |
+ const uintptr_t kLimitSize = FLAG_stack_size * KB; |
uintptr_t limit = reinterpret_cast<uintptr_t>(&limit) - kLimitSize; |
ASSERT(reinterpret_cast<uintptr_t>(&limit) > kLimitSize); |
real_jslimit_ = SimulatorStack::JsLimitFromCLimit(limit); |