RFR: Adjustments to derived-pointer handling to make it work with Shenandoah GC
Ron Pressler
rpressler at openjdk.java.net
Fri Feb 12 21:06:47 UTC 2021
On Fri, 12 Feb 2021 20:54:27 GMT, Roman Kennke <rkennke at openjdk.org> wrote:
> This adjusts derived-pointer handling to make it work with Shenandoah GC:
> - Much of it adds INCLUDE_SHENANDOAHGC and/or UseShenandoahGC where INCLUDE_ZGC and/or UseZGC already is to take the same code paths. We need to think about proper GC interfaces there.
> - In InstanceStackChunkKlass::verify(..) I changed the first load of oops to load from a local variable instead of the real field. I had troubles there because one side-effect of loading with Shenandoah barriers is that the barriers would update the field with the correct to-space reference. This throws off derived pointers which are checked later in the method.
> - Similar situation later: when loading the base of derived pointer, we may get back an updated base pointer, while the derived pointer is not yet there. Loading the raw memory seems the right way to do it.
>
> Testing:
> - [x] java/lang/Continuation (-XX:+UseShenandoahGC -XX:ShenandoahGCMode=aggressive)
> - [x] java/lang/Thread/virtual (-XX:+UseShenandoahGC -XX:ShenandoahGCMode=aggressive)
> - [x] java/lang/Continuation (-XX:+UseZGC -XX:ZCollectionInterval=0.01)
> - [x] java/lang/Thread/virtual (-XX:+UseZGC -XX:ZCollectionInterval=0.01)
Marked as reviewed by rpressler (Lead).
Marked as reviewed by rpressler (Lead).
-------------
PR: https://git.openjdk.java.net/loom/pull/30
More information about the loom-dev
mailing list