Transitioning from the previous value class model used in lw5 to the JEP 401 model requires significant changes to the VM. All those changes cannot be performed in a single step, so a more incremental approach must be used, and breakage during the initial phases of the transition must be expected.
The minimal changes required are:
- having the JVM accepting to load valid class files generated according to the JEP 401 class file format, which, which means accepting new class and field flags, supporting new type hierarchy rules, disabling some verifier rules from the previous model
- having the JVM being able to execute the new construction sequence for value instances, which means updating new and putfield bytecodes behaviors
Some clean up should be done ASAP to avoid having to fix dead code and prevent dead code to break builds, this includes:
- Removal of support of Q-descriptors (and Q-desc bit in constant pool)
- Removal of support of old class flags (ACC_VALUE)
- Removal of aconst_init and withfield bytecodes from the interpreter and C1
- Removal of support for secondary mirror
- Removal of support for primitive classes
- Removal of support for value factories ()
The minimal changes required are:
- having the JVM accepting to load valid class files generated according to the JEP 401 class file format, which, which means accepting new class and field flags, supporting new type hierarchy rules, disabling some verifier rules from the previous model
- having the JVM being able to execute the new construction sequence for value instances, which means updating new and putfield bytecodes behaviors
Some clean up should be done ASAP to avoid having to fix dead code and prevent dead code to break builds, this includes:
- Removal of support of Q-descriptors (and Q-desc bit in constant pool)
- Removal of support of old class flags (ACC_VALUE)
- Removal of aconst_init and withfield bytecodes from the interpreter and C1
- Removal of support for secondary mirror
- Removal of support for primitive classes
- Removal of support for value factories ()
- relates to
-
JDK-8325660 [lworld] Update C2 to support new value construction scheme from JEP 401
- Resolved