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

Chen Liang liach at openjdk.org
Thu Jan 8 15:08:12 UTC 2026


On Wed, 7 Jan 2026 22:11:00 GMT, Roland Mesde <duke at openjdk.org> wrote:

> 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

Beware this patch is not in a feature release yet, so it might not be sufficiently tested for production impact.

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

PR Comment: https://git.openjdk.org/jdk25u-dev/pull/135#issuecomment-3724282615


More information about the jdk-updates-dev mailing list