JDK-8227926 : add new JVM TI and JDI tests for classes loaded by Class::forName
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: svc
  • Priority: P3
  • Status: Resolved
  • Resolution: Duplicate
  • Submitted: 2019-07-17
  • Updated: 2021-06-30
  • Resolved: 2019-11-14
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 14
14Resolved
Related Reports
Blocks :  
Duplicate :  
Relates :  
Relates :  
Description
Serguei has verified that the patch for JDK-8212117 has resolved JDK-8181144.

New tests should be added to verify JVM TI and JDI behavior w.r.t. Class.forName("Foo", false, loader) returning a class that is linked.  For example:

1. JVM TI GetLoadedClasses should include "Foo" with and without the fix.
2. JVM TI GetClassStatus returns CLASS_PREPARE on "Foo" with the fix.  ClassPrepare event is also generated.
3. JDK VirtualMachine::allClasses includes "Foo" with the fix.
4. ReferenceType::isPrepared return true on "Foo" class with the fix.
Comments
Okay, I've re-linked this test enhancement to JDK-8181144.
19-11-2019

As mentioned in JDK-8181144, JDK-8233272 will not include an implementation change. This issue (JDK-8227926) can stay closed, though, if a test case is included along with the JDK-8181144 fix.
14-11-2019

I've developed new test test/hotspot/jtreg/serviceability/jvmti/ClassStatus and passed it over to Brent Christian as a test coverage for JDK-8212117. Then the fix of JDK-8212117 has been backed out. New test is still useful to provide a coverage for re-implementation (new bug is JDK-8233272). It can be used in original or modified form. So, I'm closing this test enhancement as a dup of JDK-8233272.
14-11-2019

With the backout of JDK-8212117, test/hotspot/jtreg/serviceability/jvmti/ClassStatus was removed.
04-11-2019

New test test/hotspot/jtreg/serviceability/jvmti/ClassStatus was pushed together with the fix of JDK-8212117.
18-09-2019

I believe this can now be closed as a duplicate of JDK-8212117, which includes such tests.
09-09-2019