Merge stack usage reduction for overflow checks
Cherry pick from: b038ba66a166fb264ca121632f447712e0973b5b
Change-Id: I19999e72ff731d4fc73d91b9ff767de5858c15ee
diff --git a/runtime/thread.h b/runtime/thread.h
index 120ff6f..fe950c4 100644
--- a/runtime/thread.h
+++ b/runtime/thread.h
@@ -594,16 +594,10 @@
void SetStackEndForStackOverflow() SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
// Set the stack end to that to be used during regular execution
- void ResetDefaultStackEnd(bool implicit_overflow_check) {
+ void ResetDefaultStackEnd() {
// Our stacks grow down, so we want stack_end_ to be near there, but reserving enough room
// to throw a StackOverflowError.
- if (implicit_overflow_check) {
- // For implicit checks we also need to add in the protected region above the
- // overflow region.
- tlsPtr_.stack_end = tlsPtr_.stack_begin + kStackOverflowImplicitCheckSize;
- } else {
- tlsPtr_.stack_end = tlsPtr_.stack_begin + GetStackOverflowReservedBytes(kRuntimeISA);
- }
+ tlsPtr_.stack_end = tlsPtr_.stack_begin + GetStackOverflowReservedBytes(kRuntimeISA);
}
// Install the protected region for implicit stack checks.