hotspot/src/share/vm/oops/method.hpp
changeset 13736 5b15a8f57979
parent 13728 882756847a04
child 13891 35dabd293e56
--- a/hotspot/src/share/vm/oops/method.hpp	Wed Sep 05 10:18:37 2012 -0700
+++ b/hotspot/src/share/vm/oops/method.hpp	Wed Sep 05 20:08:08 2012 -0400
@@ -168,9 +168,16 @@
                             TRAPS);
 
   Method() { assert(DumpSharedSpaces || UseSharedSpaces, "only for CDS"); }
+
+  // The Method vtable is restored by this call when the Method is in the
+  // shared archive.  See patch_klass_vtables() in metaspaceShared.cpp for
+  // all the gory details.  SA, dtrace and pstack helpers distinguish metadata
+  // by their vtable.
+  void restore_vtable() { guarantee(is_method(), "vtable restored by this call"); }
   bool is_method() const volatile { return true; }
 
   // accessors for instance variables
+
   ConstMethod* constMethod() const             { return _constMethod; }
   void set_constMethod(ConstMethod* xconst)    { _constMethod = xconst; }