RFR: 8368722: Several vector load/store tests fail on riscv without support for misaligned vector access

Hamlin Li mli at openjdk.org
Fri Sep 26 08:35:23 UTC 2025


On Fri, 26 Sep 2025 01:44:19 GMT, Dingli Zhang <dzhang at openjdk.org> wrote:

> Hi,
> Can you help to review this patch? Thanks!
> 
> In `*VectorLoadStoreTests.java`,  `loadMemorySegmentMaskIOOBE` and `storeMemorySegmentMaskIOOBE` may fail because `int index = fi.apply((int) a.byteSize())` can generate random indices that result in misaligned addresses, leading to SIGBUS on hardware that disallows misaligned vector accesses.
> 
> Some RISC-V hardware supports fast misaligned scalar accesses but not vector ones, which causes SIGBUS when executing these tests with misaligned vector memory operations.
> 
> So we should adjusted index to align with the element byte size in these tests.
> 
> ### Test
> - [x] Run jdk_vector on k1
> - [x] Run jdk_vector on x86_64 and ARM64

Hey, not check the pr yet. It's better to have a `RISC-V: ` prefix in the issue's subject.

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

PR Comment: https://git.openjdk.org/jdk/pull/27506#issuecomment-3337368103


More information about the hotspot-dev mailing list