< prev index next >

src/hotspot/share/classfile/systemDictionaryShared.cpp

Print this page
*** 56,10 ***
--- 56,11 ---
  #include "memory/metadataFactory.hpp"
  #include "memory/metaspaceClosure.hpp"
  #include "memory/oopFactory.hpp"
  #include "memory/resourceArea.hpp"
  #include "memory/universe.hpp"
+ #include "oops/compressedKlass.hpp"
  #include "oops/instanceKlass.hpp"
  #include "oops/klass.inline.hpp"
  #include "oops/objArrayOop.inline.hpp"
  #include "oops/oop.inline.hpp"
  #include "oops/oopHandle.inline.hpp"

*** 1411,12 ***
  }
  
  InstanceKlass* SystemDictionaryShared::find_builtin_class(Symbol* name) {
    const RunTimeClassInfo* record = find_record(&_builtin_dictionary, &_dynamic_builtin_dictionary, name);
    if (record != NULL) {
      assert(!record->_klass->is_hidden(), "hidden class cannot be looked up by name");
!     assert(check_alignment(record->_klass), "Address not aligned");
      // We did not save the classfile data of the regenerated LambdaForm invoker classes,
      // so we cannot support CLFH for such classes.
      if (record->_klass->is_regenerated() && JvmtiExport::should_post_class_file_load_hook()) {
         return NULL;
      }
--- 1412,17 ---
  }
  
  InstanceKlass* SystemDictionaryShared::find_builtin_class(Symbol* name) {
    const RunTimeClassInfo* record = find_record(&_builtin_dictionary, &_dynamic_builtin_dictionary, name);
    if (record != NULL) {
+ #ifdef ASSERT
+     if (UseCompressedClassPointers) {
+       CompressedKlassPointers::verify_klass_pointer(record->_klass);
+     }
+ #endif
      assert(!record->_klass->is_hidden(), "hidden class cannot be looked up by name");
!     // assert(check_alignment(record->_klass), "Address not aligned");
      // We did not save the classfile data of the regenerated LambdaForm invoker classes,
      // so we cannot support CLFH for such classes.
      if (record->_klass->is_regenerated() && JvmtiExport::should_post_class_file_load_hook()) {
         return NULL;
      }
< prev index next >