hotspot/src/share/vm/oops/methodData.hpp
changeset 28365 ccf31849c7a4
parent 27643 fe8f95a2d9bc
child 28650 772aaab2582f
--- a/hotspot/src/share/vm/oops/methodData.hpp	Thu Dec 18 04:56:27 2014 +0000
+++ b/hotspot/src/share/vm/oops/methodData.hpp	Thu Dec 18 16:15:21 2014 -0500
@@ -254,6 +254,7 @@
 
   // Redefinition support
   void clean_weak_method_links();
+  DEBUG_ONLY(void verify_clean_weak_method_links();)
 };
 
 
@@ -511,6 +512,7 @@
 
   // Redefinition support
   virtual void clean_weak_method_links() {}
+  DEBUG_ONLY(virtual void verify_clean_weak_method_links() {})
 
   // CI translation: ProfileData can represent both MethodDataOop data
   // as well as CIMethodData data. This function is provided for translating
@@ -1971,6 +1973,7 @@
   }
 
   void set_method(Method* m) {
+    assert(!m->is_old(), "cannot add old methods");
     set_intptr_at(speculative_trap_method, (intptr_t)m);
   }
 
@@ -2480,6 +2483,7 @@
 
   void clean_method_data(BoolObjectClosure* is_alive);
   void clean_weak_method_links();
+  DEBUG_ONLY(void verify_clean_weak_method_links();)
   Mutex* extra_data_lock() { return &_extra_data_lock; }
 };