RFR: 8186670: Implement _onSpinWait() intrinsic for AArch64 [v13]
Evgeny Astigeevich
duke at openjdk.java.net
Thu Oct 21 09:02:12 UTC 2021
On Wed, 20 Oct 2021 16:16:45 GMT, Andrew Haley <aph at openjdk.org> wrote:
>> Evgeny Astigeevich has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Fix formatting and spelling
>
> test/micro/org/openjdk/bench/java/lang/ThreadOnSpinWaitProducerConsumer.java line 47:
>
>> 45: @State(Scope.Benchmark)
>> 46: public class ThreadOnSpinWaitProducerConsumer {
>> 47: @Param({"100"})
>
> This test seems rather artificial and unrealistic to me. You can get improved performance simply by increasing the `spinNum` so that it waits for longer. The way to get some advantage from `onSpinWait` is to have multiple threads racing to update the same thing, e.g. to acquire a lock.
I agree with you. I am removing it.
-------------
PR: https://git.openjdk.java.net/jdk/pull/5562
More information about the hotspot-dev
mailing list