ObjectSynchronizer iterate only in-use monitors?
Roman Kennke
rkennke at redhat.com
Tue May 16 09:37:56 UTC 2017
Am 16.05.2017 um 11:24 schrieb Robbin Ehn:
> Hi,
>
> On 05/16/2017 11:13 AM, Roman Kennke wrote:
>>>>>> http://cr.openjdk.java.net/~rkennke/deflate-per-thread/webrev.01/
>
> I only had a quick look, one thing that is troubling is that:
>
> SafepointSynchronize::begin() ->
> SafepointSynchronize::do_cleanup_tasks() ->
> ObjectSynchronizer::deflate_idle_monitors()
> no longer actually deflates threads om list, so that
> ObjectSynchronizer::omAlloc(..) -> InduceScavenge() ->
> VMThread::execute(new VM_ForceAsyncSafepoint())
> do not have intended effect?
Good point!
It should be easy to solve though, by checking if (ForceMonitorScavenge)
in deflate_idle_monitors() and scavenging all monitors in this case.
Right? It comes with the disadvantage of potentially long-ish pause
though (esp. when running with many Java threads) -- but not worse than
it is now.
Roman
More information about the hotspot-runtime-dev
mailing list