diff src/share/vm/oops/method.cpp @ 8611:6c4db417385a

added API to reset the profiling information for a method added some test cases that check the recorded profiling information
author Christian Haeubl <haeubl@ssw.jku.at>
date Wed, 27 Mar 2013 17:25:59 +0100
parents b8f261ba79c6
children b9a918201d47
line wrap: on
line diff
--- a/src/share/vm/oops/method.cpp	Wed Mar 27 10:36:57 2013 +0100
+++ b/src/share/vm/oops/method.cpp	Wed Mar 27 17:25:59 2013 +0100
@@ -1940,3 +1940,15 @@
   guarantee(md == NULL ||
       md->is_methodData(), "should be method data");
 }
+
+#ifdef GRAAL
+void Method::reset_counters() {
+  invocation_counter()->reset();
+  backedge_counter()->reset();
+  _interpreter_invocation_count = 0;
+  _interpreter_throwout_count = 0;
+#ifndef PRODUCT
+  _compiled_invocation_count = 0;
+#endif
+}
+#endif