RFR: 8352218: RISC-V: Zvfh requires RVV [v2]

Robbin Ehn rehn at openjdk.org
Wed Mar 19 06:50:25 UTC 2025


On Tue, 18 Mar 2025 11:34:02 GMT, Fei Yang <fyang at openjdk.org> wrote:

>> Robbin Ehn has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
>> 
>>  - hwprobe deps
>>  - Merge branch 'master' into maxvector_0
>>  - Moved to common
>>  - Disable UseZvfh when no RVV
>
> src/hotspot/cpu/riscv/vm_version_riscv.cpp line 222:
> 
>> 220:   // UseZvbb (depends on RVV).
>> 221:   if (UseZvbb && !UseRVV) {
>> 222:     if (!FLAG_IS_DEFAULT(UseZvbb)) {
> 
> So we have two code paths to enable this flag: 1. through the command line; 2. through hwprobe. I think the issue 
> here is related to case 2. I wonder if that could be handled in that code path, that is when we call `UPDATE_DEFAULT` [1].
> 
> Then we could only consider case 1 here and simplify the code removing this `FLAG_IS_DEFAULT` check. It's a bit confusing to me as people might think that a true value of `UseZvbb` will mean that `FLAG_IS_DEFAULT` is false. What do you think?
> 
> [1] https://github.com/openjdk/jdk/blob/master/src/hotspot/cpu/riscv/vm_version_riscv.hpp#L171

I'm not sure exactly what you had in mind, but I pushed what I think you were thinking.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24094#discussion_r2002543443


More information about the hotspot-dev mailing list