RFR: Elide Evac-OOM protocol when enqueuing string deduplication candidates in traversal GC
Roman Kennke
rkennke at redhat.com
Mon Mar 19 18:43:31 UTC 2018
>> This seems slightly racy because it depends on GC not being cancelled,
>> > which might well flip over once we reach enqueue_candidate().
>
> I don't think so, but maybe miss something, so poke holes :-)
>
> There are three scenarios:
>
> 1) Cancelled by early evacuation failure by this thread, successfully
> set the flag, it should be visible.
>
> 2) Early evacuation failed, but flag was set by other thread -
> Atomic::cmpxchg() in flag->try_set() should make it visible to this thread.
>
> 3) Successfully evacuated, concelled_concgc flag set by other thread -
> it does not matter if it is visible or not.
Hmm, ok. I was most worried by scenario 2, but I think you are right.
Ok to go.
Thanks,
Roman
More information about the shenandoah-dev
mailing list