Mercurial > hg > truffle
diff src/cpu/zero/vm/cppInterpreter_zero.cpp @ 1078:8e7adf982378
6896043: first round of zero fixes
Reviewed-by: kvn
Contributed-by: Gary Benson <gbenson@redhat.com>
author | twisti |
---|---|
date | Fri, 27 Nov 2009 07:56:58 -0800 |
parents | 354d3184f6b2 |
children | b6f06e395428 |
line wrap: on
line diff
--- a/src/cpu/zero/vm/cppInterpreter_zero.cpp Tue Nov 24 11:49:42 2009 -0800 +++ b/src/cpu/zero/vm/cppInterpreter_zero.cpp Fri Nov 27 07:56:58 2009 -0800 @@ -204,6 +204,20 @@ goto unwind_and_return; } + // Update the invocation counter + if ((UseCompiler || CountCompiledCalls) && !method->is_synchronized()) { + thread->set_do_not_unlock(); + InvocationCounter *counter = method->invocation_counter(); + counter->increment(); + if (counter->reached_InvocationLimit()) { + CALL_VM_NOCHECK( + InterpreterRuntime::frequency_counter_overflow(thread, NULL)); + if (HAS_PENDING_EXCEPTION) + goto unwind_and_return; + } + thread->clr_do_not_unlock(); + } + // Lock if necessary BasicObjectLock *monitor; monitor = NULL;