-
Enhancement
-
Resolution: Unresolved
-
P3
-
None
-
None
-
None
to supply efficient checking of indexes for arrays and array-like
aggregates. These methods operate on 32-bit indexes only.
They should be duplicated to also operate on 64-bit indexes.
One customer for this API is the bounds checking of Panama
pointers. As with C, Panama pointer manipulation is important
to performance; unlike C, Panama pointers range-check their
pointers, so optimizing their range checks is a goal.
It would be sufficient for Panama to place these methods only
in jdk.internal.util.Preconditions, where the binder can get to them.
Both signed and unsigned versions of these checkers are plausible.
Panama needs only the signed 64-bit versions, at present.
- relates to
-
JDK-8042997 Make intrinsic some or all check index/range methods
- Resolved
-
JDK-8073480 C2 should optimize explicit range checks
- Resolved
-
JDK-8135248 Add utility methods to check indexes and ranges
- Resolved