[lworld] RFR: 8357461: [lworld] TestFlatInArraysFolding.java fails with UseNullableValueFlattening enabled by default

Tobias Hartmann thartmann at openjdk.org
Wed May 21 12:39:21 UTC 2025


The test expects folding of `arrayElement == oArr` in the flat array array loop version which does not happen anymore when the flat array element can be null with `-XX:+UseNullableValueFlattening` (because `oArr` can be null as well). I adjusted the test so that C2 can deduce that `oArr` is never null and can therefore fold the check.

Thanks,
Tobias

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

Commit messages:
 - 8357461: [lworld] TestFlatInArraysFolding.java fails with UseNullableValueFlattening enabled by default

Changes: https://git.openjdk.org/valhalla/pull/1469/files
  Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=1469&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8357461
  Stats: 7 lines in 1 file changed: 6 ins; 0 del; 1 mod
  Patch: https://git.openjdk.org/valhalla/pull/1469.diff
  Fetch: git fetch https://git.openjdk.org/valhalla.git pull/1469/head:pull/1469

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


More information about the valhalla-dev mailing list