[lworld] RFR: 8288135: [lworld] Implement HotSpot flag -XX:+EnablePrimitiveClasses [v12]

Frederic Parain fparain at openjdk.org
Wed Oct 5 12:03:38 UTC 2022


On Wed, 5 Oct 2022 06:28:47 GMT, David Simms <dsimms at openjdk.org> wrote:

>> Runtime component of -XX:+EnablePrimitiveClasses switch
>
> David Simms has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 24 commits:
> 
>  - Merge branch 'lworld' into 8288135
>  - Review comments applied
>  - Merge branch 'lworld' into 8288135
>  - Extra assertion info for tracking spurious issue
>  - supports_inline_types() refers to classfile and is separate from Enable flags
>  - Further testing explicity using flags
>  - Disable EnablePrimitiveClasses by default
>  - Explictly flag more tests
>  - Merge branch 'lworld' into 8288135
>  - jdk_valhalla tests
>  - ... and 14 more: https://git.openjdk.org/valhalla/compare/ee15e2d9...92e5253d

Thanks for the changes.
However, recognized modifiers still need a fix, see proposed code.

Fred

src/hotspot/share/classfile/classFileParser.cpp line 3328:

> 3326:       recognized_modifiers |= JVM_ACC_MODULE;
> 3327:     }
> 3328:     if (supports_inline_types()) {

Suggestion:
if (supports_inline_types() {
  recognized_modifiers |= JVM_ACC_VALUE | JVM_ACC_IDENTITY;
  if (EnablePrimitiveClasses) {
    recognized_modifiers |= JVM_ACC_PRIMITIVE;
  }
}

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

Changes requested by fparain (Committer).

PR: https://git.openjdk.org/valhalla/pull/727



More information about the valhalla-dev mailing list