8173100: AArch64: -XX:-UseOnStackReplacement does not work together with -XX:+TieredCompilation
Fix hotspot jtreg test compiler/interpreter/DisableOSRTest.java failure on AArch64. Reviewed-by: aph, fyang
This commit is contained in:
parent
d6bd698077
commit
34668dfd2a
@ -1904,7 +1904,8 @@ void TemplateTable::branch(bool is_jsr, bool is_wide)
|
||||
in_bytes(InvocationCounter::counter_offset()));
|
||||
const Address mask(r1, in_bytes(MethodData::backedge_mask_offset()));
|
||||
__ increment_mask_and_jump(mdo_backedge_counter, increment, mask,
|
||||
r0, rscratch1, false, Assembler::EQ, &backedge_counter_overflow);
|
||||
r0, rscratch1, false, Assembler::EQ,
|
||||
UseOnStackReplacement ? &backedge_counter_overflow : &dispatch);
|
||||
__ b(dispatch);
|
||||
}
|
||||
__ bind(no_mdo);
|
||||
@ -1912,7 +1913,8 @@ void TemplateTable::branch(bool is_jsr, bool is_wide)
|
||||
__ ldr(rscratch1, Address(rmethod, Method::method_counters_offset()));
|
||||
const Address mask(rscratch1, in_bytes(MethodCounters::backedge_mask_offset()));
|
||||
__ increment_mask_and_jump(Address(rscratch1, be_offset), increment, mask,
|
||||
r0, rscratch2, false, Assembler::EQ, &backedge_counter_overflow);
|
||||
r0, rscratch2, false, Assembler::EQ,
|
||||
UseOnStackReplacement ? &backedge_counter_overflow : &dispatch);
|
||||
} else { // not TieredCompilation
|
||||
// increment counter
|
||||
__ ldr(rscratch2, Address(rmethod, Method::method_counters_offset()));
|
||||
@ -1960,8 +1962,8 @@ void TemplateTable::branch(bool is_jsr, bool is_wide)
|
||||
}
|
||||
}
|
||||
}
|
||||
__ bind(dispatch);
|
||||
}
|
||||
__ bind(dispatch);
|
||||
|
||||
// Pre-load the next target bytecode into rscratch1
|
||||
__ load_unsigned_byte(rscratch1, Address(rbcp, 0));
|
||||
@ -1981,7 +1983,7 @@ void TemplateTable::branch(bool is_jsr, bool is_wide)
|
||||
__ b(dispatch);
|
||||
}
|
||||
|
||||
if (TieredCompilation || UseOnStackReplacement) {
|
||||
if (UseOnStackReplacement) {
|
||||
// invocation counter overflow
|
||||
__ bind(backedge_counter_overflow);
|
||||
__ neg(r2, r2);
|
||||
@ -1991,11 +1993,6 @@ void TemplateTable::branch(bool is_jsr, bool is_wide)
|
||||
CAST_FROM_FN_PTR(address,
|
||||
InterpreterRuntime::frequency_counter_overflow),
|
||||
r2);
|
||||
if (!UseOnStackReplacement)
|
||||
__ b(dispatch);
|
||||
}
|
||||
|
||||
if (UseOnStackReplacement) {
|
||||
__ load_unsigned_byte(r1, Address(rbcp, 0)); // restore target bytecode
|
||||
|
||||
// r0: osr nmethod (osr ok) or NULL (osr not possible)
|
||||
|
Loading…
Reference in New Issue
Block a user