RFR: 8344922: Redefinition verifies the new klass when verification is disabled

Coleen Phillimore coleenp at openjdk.org
Fri Dec 6 21:39:47 UTC 2024


This change only verifies redefined classes if Verification is enabled.  BytecodeVerificationRemote will be false for verification turned off.  If someone turns it off but BytecodeVerificationLocal on (which is non-sensical), the argument processing code will fix that up.  So all this needs to do is check for BytecodeVerifificationRemote for -Xverify:none (which is a deprecated option).


  // Treat the odd case where local verification is enabled but remote
  // verification is not as if both were enabled.
  if (BytecodeVerificationLocal && !BytecodeVerificationRemote) {
    log_info(verification)("Turning on remote verification because local verification is on");
    FLAG_SET_DEFAULT(BytecodeVerificationRemote, true);
  }


Tested with runtime/verifier, jck vm and tier1-4 (in progress), and the new test case.

-------------

Commit messages:
 - 8344922: Redefinition verifies the new klass when verification is disabled

Changes: https://git.openjdk.org/jdk/pull/22617/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=22617&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8344922
  Stats: 14 lines in 2 files changed: 11 ins; 0 del; 3 mod
  Patch: https://git.openjdk.org/jdk/pull/22617.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/22617/head:pull/22617

PR: https://git.openjdk.org/jdk/pull/22617


More information about the hotspot-runtime-dev mailing list