RFR: 8372845: C2: Fold identity hash code if object is constant [v3]

Chen Liang liach at openjdk.org
Tue Dec 2 23:25:29 UTC 2025


> Folding identity hash as constant if the incoming argument is constant would be useful for quick map lookups, such as for the [Classifier proposal](https://openjdk.org/jeps/8357674). Currently, identity hash is not constant because it loads the object header/mark word. We can add an explicit bypass to load an existing hash eagerly instead.

Chen Liang has updated the pull request incrementally with one additional commit since the last revision:

  Typo

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/28589/files
  - new: https://git.openjdk.org/jdk/pull/28589/files/69225241..b1d8be39

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=28589&range=02
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=28589&range=01-02

  Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
  Patch: https://git.openjdk.org/jdk/pull/28589.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/28589/head:pull/28589

PR: https://git.openjdk.org/jdk/pull/28589


More information about the hotspot-runtime-dev mailing list