RFR: 8348384: RISC-V: Disable auto-enable Vector on buggy kernels
Robbin Ehn
rehn at openjdk.org
Thu Jan 23 15:42:46 UTC 2025
On Thu, 23 Jan 2025 14:05:17 GMT, Fei Yang <fyang at openjdk.org> wrote:
>> Hi please consider!
>>
>> Linux kernels pre-6.9 can copy a dirty v-state during signal return path:
>> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/arch/riscv/kernel/signal.c?h=v6.13-rc1&id=c27fa53b858b4ee6552a719aa599c250cf98a586
>>
>> We should not auto-enable vector with such kernel, as we must be able to receive signals during the execution of vector code.
>>
>> Manual tested pre and post 6.9 as expected.
>>
>> Thanks, Robbin
>
> src/hotspot/os_cpu/linux_riscv/riscv_hwprobe.cpp line 171:
>
>> 169: long major, minor;
>> 170: os::Linux::kernel_version(&major, &minor);
>> 171: if (!(major > 6 || (major == 6 && minor >= 9))) {
>
> Seems that the kernel patch is also there in linux-6.8.y branch?
Yes, it is in 6.8.5. As ubuntu 24.04 is using 6.8 maybe we should care?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/23256#discussion_r1927194714
More information about the hotspot-runtime-dev
mailing list