Commit dc023073 authored by Lu Yahan's avatar Lu Yahan Committed by V8 LUCI CQ

[riscv64][sim] Increase the simulator's stack limit margin

Port d36f596e

Change-Id: I13c9d23bb06841e1f6cbb07c68968fb3cc9eb01a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3573784
Auto-Submit: Yahan Lu <yahan@iscas.ac.cn>
Reviewed-by: 's avatarji qiu <qiuji@iscas.ac.cn>
Commit-Queue: ji qiu <qiuji@iscas.ac.cn>
Cr-Commit-Position: refs/heads/main@{#79836}
parent ca51ae3a
......@@ -2718,9 +2718,9 @@ uintptr_t Simulator::StackLimit(uintptr_t c_limit) const {
return reinterpret_cast<uintptr_t>(get_sp());
}
// Otherwise the limit is the JS stack. Leave a safety margin of 1024 bytes
// Otherwise the limit is the JS stack. Leave a safety margin of 4 KiB
// to prevent overrunning the stack when pushing values.
return reinterpret_cast<uintptr_t>(stack_) + 1024;
return reinterpret_cast<uintptr_t>(stack_) + 4 * KB;
}
// Unsupported instructions use Format to print an error and stop execution.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment