-
Bug
-
Resolution: Fixed
-
P3
-
9
-
b21
From [~mgerdin] There are still a bunch of *Klass methods which are static and have an InstanceKlass* (which used to be a handle) as their first parameter. Do you want to leave that to a future cleanup or fold it into this change?
Example:
1309 // Static methods that are used to implement member methods where an exposed this pointer
1310 // is needed due to possible GCs
1311 static bool link_class_impl (instanceKlassHandle this_k, bool throw_verifyerror, TRAPS);
1312 static bool verify_code (instanceKlassHandle this_k, bool throw_verifyerror, TRAPS);
1313 static void initialize_impl (instanceKlassHandle this_k, TRAPS);
1314 static void initialize_super_interfaces (instanceKlassHandle this_k, TRAPS);
1315 static void eager_initialize_impl (instanceKlassHandle this_k);
1316 static void set_initialization_state_and_notify_impl (instanceKlassHandle this_k, ClassState state, TRAPS);
1317 static void call_class_initializer_impl (instanceKlassHandle this_k, TRAPS);
1318 static Klass* array_klass_impl (instanceKlassHandle this_k, bool or_null, int n, TRAPS);
1319 static void do_local_static_fields_impl (instanceKlassHandle this_k, void f(fieldDescriptor* fd, Handle, TRAPS), Handle, TRAPS);
1320 /* jni_id_for_impl for jfieldID only */
1321 static JNIid* jni_id_for_impl (instanceKlassHandle this_k, int offset);
1322
All the above should probably be nonstatic member functions on InstanceKlass instead but had to be made static since a permgen gc could have moved "this" out from under the execution.
Fix this after push for removing KlassHandles
Example:
1309 // Static methods that are used to implement member methods where an exposed this pointer
1310 // is needed due to possible GCs
1311 static bool link_class_impl (instanceKlassHandle this_k, bool throw_verifyerror, TRAPS);
1312 static bool verify_code (instanceKlassHandle this_k, bool throw_verifyerror, TRAPS);
1313 static void initialize_impl (instanceKlassHandle this_k, TRAPS);
1314 static void initialize_super_interfaces (instanceKlassHandle this_k, TRAPS);
1315 static void eager_initialize_impl (instanceKlassHandle this_k);
1316 static void set_initialization_state_and_notify_impl (instanceKlassHandle this_k, ClassState state, TRAPS);
1317 static void call_class_initializer_impl (instanceKlassHandle this_k, TRAPS);
1318 static Klass* array_klass_impl (instanceKlassHandle this_k, bool or_null, int n, TRAPS);
1319 static void do_local_static_fields_impl (instanceKlassHandle this_k, void f(fieldDescriptor* fd, Handle, TRAPS), Handle, TRAPS);
1320 /* jni_id_for_impl for jfieldID only */
1321 static JNIid* jni_id_for_impl (instanceKlassHandle this_k, int offset);
1322
All the above should probably be nonstatic member functions on InstanceKlass instead but had to be made static since a permgen gc could have moved "this" out from under the execution.
Fix this after push for removing KlassHandles
- relates to
-
JDK-8178107 Compiler crashes with "assert(get_instanceKlass()->is_loaded()) failed: must be at least loaded"
-
- Resolved
-
-
JDK-8155672 Remove instanceKlassHandles and KlassHandles
-
- Resolved
-
-
JDK-8182720 In InstanceKlass.cpp, get init_lock from handle
-
- Resolved
-