# HG changeset patch # User iveresov # Date 1317362994 25200 # Node ID dc45ae774613f9e0d19cc145059b7526d540d9da # Parent 098acdf97f096a3e3978cc0917aff9dea229622c 7096639: Tiered: Incorrect counter overflow handling for inlined methods Summary: Enable invocation events for inlinees Reviewed-by: kvn diff -r 098acdf97f09 -r dc45ae774613 src/share/vm/c1/c1_LIRGenerator.cpp --- a/src/share/vm/c1/c1_LIRGenerator.cpp Thu Sep 29 13:47:57 2011 -0700 +++ b/src/share/vm/c1/c1_LIRGenerator.cpp Thu Sep 29 23:09:54 2011 -0700 @@ -2970,8 +2970,8 @@ // accessors are also always mature. if (!x->inlinee()->is_accessor()) { CodeEmitInfo* info = state_for(x, x->state(), true); - // Increment invocation counter, don't notify the runtime, because we don't inline loops, - increment_event_counter_impl(info, x->inlinee(), 0, InvocationEntryBci, false, false); + // Notify the runtime very infrequently only to take care of counter overflows + increment_event_counter_impl(info, x->inlinee(), (1 << Tier23InlineeNotifyFreqLog) - 1, InvocationEntryBci, false, true); } } diff -r 098acdf97f09 -r dc45ae774613 src/share/vm/runtime/globals.hpp --- a/src/share/vm/runtime/globals.hpp Thu Sep 29 13:47:57 2011 -0700 +++ b/src/share/vm/runtime/globals.hpp Thu Sep 29 23:09:54 2011 -0700 @@ -3521,6 +3521,9 @@ "C1 with MDO profiling (tier 3) invocation notification " \ "frequency.") \ \ + product(intx, Tier23InlineeNotifyFreqLog, 20, \ + "Inlinee invocation (tiers 2 and 3) notification frequency") \ + \ product(intx, Tier0BackedgeNotifyFreqLog, 10, \ "Interpreter (tier 0) invocation notification frequency.") \ \