RFR (S): 8151499: gc/g1/g1OopClosures.inline.hpp: assert(_from->is_in_reserved(p)) failed: p is not in from

Thomas Schatzl thomas.schatzl at oracle.com
Fri Apr 1 13:05:34 UTC 2016


Hi all,

  can I have reviews for the fix of a wrong assert in
g1OopClosure.inline.hpp?

The assert tried to make sure that for a given pointer to an oop p, the
"_from" region stored in the closure matches.

This is not true for a humongous non-array of references object: for
these we mark only the header dirty, and during investigation of a
particular card/reference, we need to go over all references of that
object.

Since in this case, other references may not be in the same region as
p, the assert _from->is_in_reserved(p) fails since the change in JDK
-8139867.

While trying to think through the code, I added a note about additional
but benign remembered set entries that might be added while executing
the method to explain the issue a bit if you dare to think through the
entire code.

Thanks go to A. Shipilev for the test.

CR:
https://bugs.openjdk.java.net/browse/JDK-8151499
Webrev:
http://cr.openjdk.java.net/~tschatzl/8151499/webrev/
Testing:
test case runs successfully, jprt, runs of gcbasher with 
-XX:+G1VerifyRememberedSets

Thanks,
  Thomas



More information about the hotspot-gc-dev mailing list