RFR: Traversal: Purge arraycopy 'optimization'

Roman Kennke rkennke at redhat.com
Thu Aug 2 20:54:17 UTC 2018


We have an 'optimization' for arraycopy and TraversalGC: we attempt to
offload the actual scanning+traversing of copied arrays to GC workers.
However, there a a number of problems with this approach:
- Termination: mutators can keep pushing work to GC workers, which would
then not terminate and run into degen and/or full-gc. I've actualy seen
this with some workloads.
- Locking: arraycopy barrier code is called as leaf, which means it must
not use locks. bad bad us.
- More locking: this stuff is not scalable. we can currently only keep
threads from trampling over each other feet by cranking up the threshold.

Also, since we have not yet seen an actual benefit of the approach,
let's drop it. If we ever see arraycopies to be a problem that needs
fixing, we can find it in the hg history.

http://cr.openjdk.java.net/~rkennke/traversal-kill-arraycopy/webrev.00/

Testing: tier1_gc_shenandoah

Roman



More information about the shenandoah-dev mailing list