< prev index next >

src/hotspot/share/runtime/sharedRuntime.cpp


*** 1393,1402 **** --- 1393,1403 ---- // virtual this is just a destination address. // Patching IC caches may fail if we run out if transition stubs. // We refill the ic stubs then and try again. for (;;) { + DEBUG_ONLY(ICRefillVerifier ic_refill_verifier;) bool successful = resolve_sub_helper_internal(callee_method, caller_frame, caller_nm, is_virtual, is_optimized, receiver, call_info, invoke_code, CHECK_(methodHandle())); if (successful) { return callee_method; ***************
*** 1601,1614 **** } } else if (!inline_cache->is_megamorphic() && !inline_cache->is_clean()) { // Potential change to megamorphic bool successful = inline_cache->set_to_megamorphic(&call_info, bc, needs_ic_stub_refill, CHECK_false); if (!successful) { - if (!needs_ic_stub_refill) { - return false; - } if (!inline_cache->set_to_clean()) { needs_ic_stub_refill = true; return false; } } --- 1602,1615 ---- } } else if (!inline_cache->is_megamorphic() && !inline_cache->is_clean()) { // Potential change to megamorphic bool successful = inline_cache->set_to_megamorphic(&call_info, bc, needs_ic_stub_refill, CHECK_false); + if (needs_ic_stub_refill) { + return false; + } if (!successful) { if (!inline_cache->set_to_clean()) { needs_ic_stub_refill = true; return false; } } ***************
*** 1688,1697 **** --- 1689,1699 ---- frame caller_frame = thread->last_frame().sender(&reg_map); CodeBlob* cb = caller_frame.cb(); CompiledMethod* caller_nm = cb->as_compiled_method(); for (;;) { + DEBUG_ONLY(ICRefillVerifier ic_refill_verifier;) bool needs_ic_stub_refill = false; bool successful = handle_ic_miss_helper_internal(receiver, caller_nm, caller_frame, callee_method, bc, call_info, needs_ic_stub_refill, CHECK_(methodHandle())); if (successful || !needs_ic_stub_refill) { return callee_method; ***************
*** 1796,1805 **** --- 1798,1808 ---- // leads to very hard to track down bugs, if an inline cache gets updated // to a wrong method). It should not be performance critical, since the // resolve is only done once. for (;;) { + DEBUG_ONLY(ICRefillVerifier ic_refill_verifier;) if (!clear_ic_at_addr(caller_nm, call_addr, is_static_call)) { InlineCacheBuffer::refill_ic_stubs(); } else { break; }
< prev index next >