@@ -899,16 +899,15 @@ InstanceKlass* SystemDictionary::resolve_instance_class_or_null(Symbol* name,
899
899
// _dictionary->bucket(index) is read here, so the caller will not see
900
900
// the new entry.
901
901
902
- Klass* SystemDictionary::find (Symbol* class_name,
903
- Handle class_loader,
904
- Handle protection_domain,
905
- TRAPS) {
902
+ InstanceKlass* SystemDictionary::find_instance_klass (Symbol* class_name,
903
+ Handle class_loader,
904
+ Handle protection_domain) {
906
905
907
906
// The result of this call should be consistent with the result
908
907
// of the call to resolve_instance_class_or_null().
909
908
// See evaluation 6790209 and 4474172 for more details.
910
- class_loader = Handle (THREAD, java_lang_ClassLoader::non_reflection_class_loader (class_loader () ));
911
- ClassLoaderData* loader_data = ClassLoaderData::class_loader_data_or_null (class_loader () );
909
+ oop class_loader_oop = java_lang_ClassLoader::non_reflection_class_loader (class_loader ());
910
+ ClassLoaderData* loader_data = ClassLoaderData::class_loader_data_or_null (class_loader_oop );
912
911
913
912
if (loader_data == NULL ) {
914
913
// If the ClassLoaderData has not been setup,
@@ -918,16 +917,14 @@ Klass* SystemDictionary::find(Symbol* class_name,
918
917
919
918
Dictionary* dictionary = loader_data->dictionary ();
920
919
unsigned int name_hash = dictionary->compute_hash (class_name);
921
- return dictionary->find (name_hash, class_name,
922
- protection_domain);
920
+ return dictionary->find (name_hash, class_name, protection_domain);
923
921
}
924
922
925
923
// Look for a loaded instance or array klass by name. Do not do any loading.
926
924
// return NULL in case of error.
927
925
Klass* SystemDictionary::find_instance_or_array_klass (Symbol* class_name,
928
926
Handle class_loader,
929
- Handle protection_domain,
930
- TRAPS) {
927
+ Handle protection_domain) {
931
928
Klass* k = NULL ;
932
929
assert (class_name != NULL , " class name must be non NULL" );
933
930
@@ -941,13 +938,13 @@ Klass* SystemDictionary::find_instance_or_array_klass(Symbol* class_name,
941
938
if (t != T_OBJECT) {
942
939
k = Universe::typeArrayKlassObj (t);
943
940
} else {
944
- k = SystemDictionary::find (ss.as_symbol (), class_loader, protection_domain, THREAD );
941
+ k = SystemDictionary::find_instance_klass (ss.as_symbol (), class_loader, protection_domain);
945
942
}
946
943
if (k != NULL ) {
947
944
k = k->array_klass_or_null (ndims);
948
945
}
949
946
} else {
950
- k = find (class_name, class_loader, protection_domain, THREAD );
947
+ k = find_instance_klass (class_name, class_loader, protection_domain);
951
948
}
952
949
return k;
953
950
}
@@ -1219,7 +1216,7 @@ bool SystemDictionary::check_shared_class_super_type(InstanceKlass* klass, Insta
1219
1216
if (!super_type->is_shared_unregistered_class () && super_type->class_loader_data () != NULL ) {
1220
1217
// Check if the super class is loaded by the current class_loader
1221
1218
Symbol* name = super_type->name ();
1222
- Klass * check = find (name, class_loader, protection_domain, CHECK_0 );
1219
+ InstanceKlass * check = find_instance_klass (name, class_loader, protection_domain);
1223
1220
if (check == super_type) {
1224
1221
return true ;
1225
1222
}
@@ -1897,7 +1894,7 @@ Klass* SystemDictionary::find_constrained_instance_or_array_klass(
1897
1894
// Force the protection domain to be null. (This removes protection checks.)
1898
1895
Handle no_protection_domain;
1899
1896
Klass* klass = find_instance_or_array_klass (class_name, class_loader,
1900
- no_protection_domain, CHECK_NULL );
1897
+ no_protection_domain);
1901
1898
if (klass != NULL )
1902
1899
return klass;
1903
1900
0 commit comments