--- a/hotspot/src/share/vm/oops/instanceKlass.hpp Sat Jul 22 15:54:27 2017 -0400
+++ b/hotspot/src/share/vm/oops/instanceKlass.hpp Wed Aug 02 18:06:38 2017 -0700
@@ -142,6 +142,9 @@
static InstanceKlass* allocate_instance_klass(const ClassFileParser& parser, TRAPS);
protected:
+ // If you add a new field that points to any metaspace object, you
+ // must add this field to InstanceKlass::metaspace_pointers_do().
+
// Annotations for this class
Annotations* _annotations;
// Package this class is defined in
@@ -1341,6 +1344,8 @@
// JVMTI support
jint jvmti_class_status() const;
+ virtual void metaspace_pointers_do(MetaspaceClosure* iter);
+
public:
// Printing
#ifndef PRODUCT