RFR: 8224966: ZGC: Don't skip oop verification in OopMapSet::all_do()
Stefan Karlsson
stefan.karlsson at oracle.com
Wed Jun 5 08:22:42 UTC 2019
On 2019-05-29 11:27, Per Liden wrote:
> When ZGC is enabled, we skip oop verification in OopMapSet::all_do().
> There's no good reason to skip that. The comment suggesting this is
> skipped because a safepoint can happen between a load and the barrier is
> incorrect. We can still do the verification as is_in_or_null() doesn't
> require the address to have a "good" color.
I think the comment is correct. The following situation can cause
failure in the verification:
register = Object.field
safepoint
load barrier for register
If Object.field points into the old collection set, and we perform a
mark start or mark end pause, we'll perform a stack walk and hit this
assert because Heap::is_in_or_null(Object.field) will return false.
I applied the patch and ran stress testing with large collection sets,
and eventually hit this assert during the mark start phase.
>
> Also, once JDK-8224675 is integrated, this comment will make even less
> sense.
Right. After Nils' changes this shouldn't be a problem anymore.
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-8224966
> Webrev: http://cr.openjdk.java.net/~pliden/8224966/webrev.0
Looks good, after Nils' changes have been pushed.
StefanK
>
> /Per
More information about the hotspot-gc-dev
mailing list