-
Type:
Enhancement
-
Resolution: Fixed
-
Priority:
P4
-
Affects Version/s: 25
-
Component/s: hotspot
When working on JDK-8351140, I witnessed possible misaligned memory access in array fill stub.
We fill by element for short arrays (< 8 bytes), which assumes a heapword alignment. But that is not guaranteed. This issue could be reproduced by running: `make test TEST="micro:vm.compiler.ArrayFill"`
with `@Param("5") private int size;` on riscv platforms with slow misalgned memory accesses.
[1] https://github.com/openjdk/jdk/blob/master/src/hotspot/cpu/riscv/stubGenerator_riscv.cpp#L2141
We fill by element for short arrays (< 8 bytes), which assumes a heapword alignment. But that is not guaranteed. This issue could be reproduced by running: `make test TEST="micro:vm.compiler.ArrayFill"`
with `@Param("5") private int size;` on riscv platforms with slow misalgned memory accesses.
[1] https://github.com/openjdk/jdk/blob/master/src/hotspot/cpu/riscv/stubGenerator_riscv.cpp#L2141
- links to
-
Commit(master)
openjdk/jdk/d7cb933b
-
Review(master)
openjdk/jdk/25135