OpenJDK / amber / amber
changeset 60260:4a5a7dc9d05c
8240267: VM fails to start with CDS enabled but JVMTI disabled
Reviewed-by: dholmes
author | iklam |
---|---|
date | Sun, 01 Mar 2020 17:36:03 -0800 |
parents | 1e4e7bf0b6f5 |
children | 4b9d816b1531 ed5224c3e044 |
files | src/hotspot/share/classfile/javaClasses.cpp src/hotspot/share/classfile/systemDictionary.cpp |
diffstat | 2 files changed, 5 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/src/hotspot/share/classfile/javaClasses.cpp Wed Feb 26 17:32:04 2020 +0800 +++ b/src/hotspot/share/classfile/javaClasses.cpp Sun Mar 01 17:36:03 2020 -0800 @@ -4782,9 +4782,9 @@ // Compute non-hard-coded field offsets of all the classes in this file void JavaClasses::compute_offsets() { if (UseSharedSpaces) { - assert(JvmtiExport::is_early_phase() && !(JvmtiExport::should_post_class_file_load_hook() && - JvmtiExport::has_early_class_hook_env()), - "JavaClasses::compute_offsets() must be called in early JVMTI phase."); + JVMTI_ONLY(assert(JvmtiExport::is_early_phase() && !(JvmtiExport::should_post_class_file_load_hook() && + JvmtiExport::has_early_class_hook_env()), + "JavaClasses::compute_offsets() must be called in early JVMTI phase.")); // None of the classes used by the rest of this function can be replaced by // JMVTI ClassFileLoadHook. // We are safe to use the archived offsets, which have already been restored
--- a/src/hotspot/share/classfile/systemDictionary.cpp Wed Feb 26 17:32:04 2020 +0800 +++ b/src/hotspot/share/classfile/systemDictionary.cpp Sun Mar 01 17:36:03 2020 -0800 @@ -2070,8 +2070,8 @@ #ifdef ASSERT if (UseSharedSpaces) { - assert(JvmtiExport::is_early_phase(), - "All well known classes must be resolved in JVMTI early phase"); + JVMTI_ONLY(assert(JvmtiExport::is_early_phase(), + "All well known classes must be resolved in JVMTI early phase")); for (int i = FIRST_WKID; i < last; i++) { InstanceKlass* k = _well_known_klasses[i]; assert(k->is_shared(), "must not be replaced by JVMTI class file load hook");