--- old/src/hotspot/share/classfile/javaClasses.cpp 2018-03-20 16:07:21.753779041 +0100 +++ new/src/hotspot/share/classfile/javaClasses.cpp 2018-03-20 16:07:21.435783300 +0100 @@ -1866,7 +1866,7 @@ oop java_lang_Throwable::unassigned_stacktrace() { InstanceKlass* ik = SystemDictionary::Throwable_klass(); - oop base = ik->static_field_base(); + oop base = ik->static_field_base_raw(); return base->obj_field(static_unassigned_stacktrace_offset); } @@ -3543,13 +3543,13 @@ jlong java_lang_ref_SoftReference::clock() { InstanceKlass* ik = SystemDictionary::SoftReference_klass(); - oop base = ik->static_field_base(); + oop base = ik->static_field_base_raw(); return base->long_field(static_clock_offset); } void java_lang_ref_SoftReference::set_clock(jlong value) { InstanceKlass* ik = SystemDictionary::SoftReference_klass(); - oop base = ik->static_field_base(); + oop base = ik->static_field_base_raw(); base->long_field_put(static_clock_offset, value); } @@ -4129,7 +4129,7 @@ bool java_lang_System::has_security_manager() { InstanceKlass* ik = SystemDictionary::System_klass(); - oop base = ik->static_field_base(); + oop base = ik->static_field_base_raw(); return !oopDesc::is_null(base->obj_field(static_security_offset)); } --- old/src/hotspot/share/jvmci/jvmciJavaClasses.hpp 2018-03-20 16:07:22.765765488 +0100 +++ new/src/hotspot/share/jvmci/jvmciJavaClasses.hpp 2018-03-20 16:07:22.471769425 +0100 @@ -353,7 +353,7 @@ static type name() { \ assert(klassName::klass() != NULL && klassName::klass()->is_linked(), "Class not yet linked: " #klassName); \ InstanceKlass* ik = klassName::klass(); \ - oop base = ik->static_field_base(); \ + oop base = ik->static_field_base_raw(); \ oop result = HeapAccess<>::oop_load_at(base, _##name##_offset); \ return type(result); \ } \ @@ -361,22 +361,22 @@ assert(klassName::klass() != NULL && klassName::klass()->is_linked(), "Class not yet linked: " #klassName); \ assert(klassName::klass() != NULL, "Class not yet loaded: " #klassName); \ InstanceKlass* ik = klassName::klass(); \ - oop base = ik->static_field_base(); \ - HeapAccess<>::oop_store_at(base, _##name##_offset, x); \ + oop base = ik->static_field_base_raw(); \ + HeapAccess<>::oop_store_at(base, _##name##_offset, x); \ } #define STATIC_PRIMITIVE_FIELD(klassName, name, jtypename) \ static int _##name##_offset; \ static jtypename name() { \ assert(klassName::klass() != NULL && klassName::klass()->is_linked(), "Class not yet linked: " #klassName); \ InstanceKlass* ik = klassName::klass(); \ - oop base = ik->static_field_base(); \ - return HeapAccess<>::load_at(base, _##name##_offset); \ + oop base = ik->static_field_base_raw(); \ + return HeapAccess<>::load_at(base, _##name##_offset); \ } \ static void set_##name(jtypename x) { \ assert(klassName::klass() != NULL && klassName::klass()->is_linked(), "Class not yet linked: " #klassName); \ InstanceKlass* ik = klassName::klass(); \ - oop base = ik->static_field_base(); \ - HeapAccess<>::store_at(base, _##name##_offset, x); \ + oop base = ik->static_field_base_raw(); \ + HeapAccess<>::store_at(base, _##name##_offset, x); \ } #define STATIC_INT_FIELD(klassName, name) STATIC_PRIMITIVE_FIELD(klassName, name, jint) --- old/src/hotspot/share/oops/instanceKlass.hpp 2018-03-20 16:07:23.725752631 +0100 +++ new/src/hotspot/share/oops/instanceKlass.hpp 2018-03-20 16:07:23.421756703 +0100 @@ -1070,7 +1070,7 @@ int itable_offset_in_words() const { return start_of_itable() - (intptr_t*)this; } - oop static_field_base() { return java_mirror(); } + oop static_field_base_raw() { return java_mirror(); } OopMapBlock* start_of_nonstatic_oop_maps() const { return (OopMapBlock*)(start_of_itable() + itable_length());