-
Enhancement
-
Resolution: Unresolved
-
P4
-
repo-lilliput
We need microbenchmarks to measure performance of System.identityHashCode() calls. In particular, to cover different scenarios of compact identity hashcode (JDK-8320761), we should test performance of:
- identityHashCode() on objects that don't get moved by GC (to test state 01, hashed-but-not-expanded?)
- identityHashCode() on objects that have been moved by GC, after identityHashCode() has been called at least once (to test state 11, hashed-and-expanded)
As a bonus, it would be nice to test performance of the second scenario above, once with C2 knowing the exact type of the object (in which case C2 can avoid loading the Klass* and its hash_offset at run-time, and can do so at compile-time) vs when C2 can not determine the exact type (in which case, C2 needs to generate code to load the Klass* and its hash_offset at run-time, which must be significantly slower).
- identityHashCode() on objects that don't get moved by GC (to test state 01, hashed-but-not-expanded?)
- identityHashCode() on objects that have been moved by GC, after identityHashCode() has been called at least once (to test state 11, hashed-and-expanded)
As a bonus, it would be nice to test performance of the second scenario above, once with C2 knowing the exact type of the object (in which case C2 can avoid loading the Klass* and its hash_offset at run-time, and can do so at compile-time) vs when C2 can not determine the exact type (in which case, C2 needs to generate code to load the Klass* and its hash_offset at run-time, which must be significantly slower).
- is blocked by
-
JDK-8320761 [Lilliput] Implement compact identity hashcode
-
- Resolved
-