RFR: 8319211: Regression in LoopOverNonConstantFP
Maurizio Cimadamore
mcimadamore at openjdk.org
Wed Nov 1 14:17:11 UTC 2023
This PR fixes an inexact var handle call that sneaked in as part of https://git.openjdk.org/jdk/pull/16224.
As some default methods were moved from `MemorySegment` to `AbstractMemorySegmentImpl`, the type of `this` has changed, and this made all the var handle calls in the memory segment accessors inexact.
To prevent this issue from occurring again, I've added a new JDK flag to create _exact_ segment view var handles, so that we can test that segment accessors work even when using the stricter behavior.
I've considered using a flag for _all_ var handles (even non-FFM ones), but gave up when I saw that there is some JDK code that needs to pass `null` to some var handles, in which case exact behavior is not possible (at least not without fixing the use site to cast the `null` to the right type). This might be pursued as a separate effort.
-------------
Commit messages:
- Initial push
Changes: https://git.openjdk.org/jdk/pull/16451/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=16451&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8319211
Stats: 42 lines in 4 files changed: 5 ins; 0 del; 37 mod
Patch: https://git.openjdk.org/jdk/pull/16451.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/16451/head:pull/16451
PR: https://git.openjdk.org/jdk/pull/16451
More information about the core-libs-dev
mailing list