Integrated: 8335269: [Graal] occasional timeout in java/lang/StringBuffer/TestSynchronization.java with loom
Patricio Chilano Mateo
pchilanomate at openjdk.org
Mon Jul 15 14:56:59 UTC 2024
On Wed, 3 Jul 2024 19:54:46 GMT, Patricio Chilano Mateo <pchilanomate at openjdk.org> wrote:
> Please review the following simple fix. A pinned virtual thread calling Thread.yield() in a loop might never poll for safepoints if the compiler relies on a poll in native method Continuation.doYield while optimizing. This is a special native method that doesn't always poll for safepoints, and in particular it doesn't if the virtual thread is pinned due to owning monitors. Currently this scenario can be reproduced with the Graal compiler.
>
> I included a test which reproduces the issue with Graal (couldn't reproduce the issue with c2). The test times out without the fix and passes with it. I also run the patch through mach5 tiers1-3.
>
> Thanks,
> Patricio
This pull request has now been integrated.
Changeset: 000de306
Author: Patricio Chilano Mateo <pchilanomate at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/000de306286bb75bbdad2f572ce6dafd4184680e
Stats: 84 lines in 2 files changed: 84 ins; 0 del; 0 mod
8335269: [Graal] occasional timeout in java/lang/StringBuffer/TestSynchronization.java with loom
Reviewed-by: dholmes, alanb
-------------
PR: https://git.openjdk.org/jdk/pull/20016
More information about the hotspot-dev
mailing list