[jdk25u-dev] RFR: 8366424: Missing type profiling in generated Record Object methods

Roland Mesde duke at openjdk.org
Wed Jan 7 22:59:28 UTC 2026


Backporting JDK-8366424: Missing type profiling in generated Record Object methods.

This commit addresses a HotSpot profiling issue where shared bytecode causes "profile pollution" - multiple call sites sharing the same method profile, degrading type profiling effectiveness.

This backport has internal demand 

Ran benchmark on macos-aarch64:


Benchmark                                  Mode  Cnt     Score    Error   Units
RecordMethodsBenchmark.equalsDistinct     thrpt   15   346.810 ±  4.077  ops/us
RecordMethodsBenchmark.equalsGenerated    thrpt   15   345.344 ±  2.830  ops/us
RecordMethodsBenchmark.equalsPolluted     thrpt   15   146.948 ±  3.605  ops/us
RecordMethodsBenchmark.equalsSpecial      thrpt   15   433.302 ±  6.331  ops/us
RecordMethodsBenchmark.hashCodeDistinct   thrpt   15   869.551 ± 11.816  ops/us
RecordMethodsBenchmark.hashCodeGenerated  thrpt   15   872.454 ± 11.104  ops/us
RecordMethodsBenchmark.hashCodePolluted   thrpt   15   215.734 ±  1.739  ops/us
RecordMethodsBenchmark.hashCodeSpecial    thrpt   15  1025.061 ± 10.919  ops/us

Results attached:

[macos-aarch64-benchmark.log](https://github.com/user-attachments/files/24484067/macos-aarch64-benchmark.log)

Ran related tests (passed) on linux-x64, linux-aarch64, macos-aarch64 and windows-x64:

(Passed) - make test TEST=test/jdk/java/lang/runtime

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

Commit messages:
 - Backport 43e036ba89dc8a09129313705f61354463d2c266

Changes: https://git.openjdk.org/jdk25u-dev/pull/135/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk25u-dev&pr=135&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8366424
  Stats: 367 lines in 2 files changed: 317 ins; 18 del; 32 mod
  Patch: https://git.openjdk.org/jdk25u-dev/pull/135.diff
  Fetch: git fetch https://git.openjdk.org/jdk25u-dev.git pull/135/head:pull/135

PR: https://git.openjdk.org/jdk25u-dev/pull/135


More information about the jdk-updates-dev mailing list