RFR(S): 8229422: Taskqueue: Outdated selection of weak memory model platforms

Kim Barrett kim.barrett at oracle.com
Mon Aug 12 18:35:30 UTC 2019


> On Aug 12, 2019, at 1:33 PM, Doerr, Martin <martin.doerr at sap.com> wrote:
> 
> Hi,
> 
> I recently noticed that the selection of weak memory model platforms is outdated in the task queue implementation:
> s390 is unnecessarily treated as weak memory model platform.
> 
> I could simply fix it by adding "defined S390", but I'd like to get rid of the platform whitelist in the middle of the implementation.
> 
> My favorite implementation looks like this:
> http://cr.openjdk.java.net/~mdoerr/8229422_multi-copy-atomic/webrev.00/
> 
> I've moved the selection to the platform files. They define if they have the required property.
> I have also cleaned up some PPC64 related stuff which should use the same property.
> The change really improves only s390. It's only cleanup for other ones (no functional change).
> 
> I'd like to get reviews from GC first. I guess I'll have to get reviews from runtime and compiler afterwards, too.
> 
> Thanks and best regards,
> Martin

Based on the code in pop_global and the comment explaining the need
for the barrier, I wonder whether a full fence is needed. It seems
like having an acquire barrier for _age.get() would be sufficient.
That we don't need an explicit barrier for the listed architectures
also argues that an acquire barrier is sufficient. And then we
wouldn't need the architecture-based conditionalization, as it would
be handled appropriately by the platform-specific implementation of
the acquire barrier.




More information about the hotspot-gc-dev mailing list