[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-hotspot-runtime-dev
Subject: Re: RFC: Piggy-back monitor-deflation and nmethod-marking on GC
From: David Holmes <david.holmes () oracle ! com>
Date: 2018-09-17 3:52:29
Message-ID: 2a4c820c-fefd-8355-61c1-949662132901 () oracle ! com
[Download RAW message or body]
Hi Roman,
On 14/09/2018 5:36 PM, Roman Kennke wrote:
> Regarding those issues:
>
> https://bugs.openjdk.java.net/browse/JDK-8132849
> https://bugs.openjdk.java.net/browse/JDK-8132849
>
> I.e. increased pause times caused by monitor-deflation and
> nmethod-marking, there has been the suggestion by the reporter to
> piggy-back those activities on GC thread-scanning.
>
> We do have code in Shenandoah that does this since quite a while.
>
> The idea is to introduce two new methods in VM_Operation:
>
> virtual bool deflates_idle_monitors();
> virtual bool marks_nmethods();
>
> That basically tell the runtime whether or not a particular VM_Operation
> (e.g. InitMark) can take over any of the two activties, and if so, skip
> the corresponding activity in the preceding SP-cleanup phase. This means
> that the VM_Operation needs to handle this itself. The change also
> includes some changes in sychronizer, thread etc to make this relatively
> easy to implement from a GC standpoint.
So the VM_op hands off these tasks to GC threads?
This seems a bit "klunky" to me. What you're basically achieving is
concurrent cleanup whilst still at a safepoint, but this really has
nothing to do with GC - you're just "hijacking" the GC threads because
it is convenient.
I'd rather see a more concerted effort to avoid having a monitor
deflation problem in the first place - as per my comment in JDK-8153224.
That is a slightly different, but related, goal to the JEP.
Cheers,
David
> Question: would there be interest in getting this upstreamed? If so, I
> would put together a patch for reviewing.
>
> Alternatively or additionally, at least for monitor deflation, there is
> the JEP Draft: Concurrent Monitor Deflation:
> https://bugs.openjdk.java.net/browse/JDK-8183909
>
> But this seems like a very serious amount of work.
>
> WDYT?
>
> Roman
>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic