RFR: 8321282: RISC-V: SpinPause() not implemented [v2]

Fredrik Bredberg fbredberg at openjdk.org
Tue Feb 13 12:30:03 UTC 2024


On Tue, 13 Feb 2024 08:26:02 GMT, Robbin Ehn <rehn at openjdk.org> wrote:

>> Hi, please consider.
>> 
>> Tested tier1 and targeted via gtest WaitBarrier which uses SpinPause(). (with UseZihintpause default true)
>
> Robbin Ehn has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Removed memory clobber

src/hotspot/os_cpu/linux_riscv/os_linux_riscv.cpp line 415:

> 413:       // To do: __asm__ volatile("pause " : : : );
> 414:       // We need to compile against march with zihintpause.
> 415:       // Currently we do not.

Just a small improvement suggestion:

      // Since we're currently not passing '-march=..._zihintpause' to the compiler,
      // it will not recognize the "pause" instruction, hence the hard-coded instruction.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/17820#discussion_r1487615777


More information about the hotspot-runtime-dev mailing list