Small issue with array chunking in G1 (original) (raw)
Tony Printezis tprintezis at twitter.com
Thu Jan 30 16:29:24 UTC 2014
- Previous message (by thread): RFR (XXS): 8033106 Wrong predicate for checking whether the correct amount of symbol table entries have been processed in G1
- Next message (by thread): Small issue with array chunking in G1
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
(looking at Thomas' recent change reminded me that I've been meaning to ask about this)
Talking about array chunking in G1, we noticed a small difference in that code compared to what the other GCs (ParNew / PS) do. G1 uses the to-space length field to encode how much of the array has been scanned (i.e., the from-space length field is always correct). ParNew and PS use the from-space length field (and the to-space length field is always correct). I came across that issue when I was working on a change to periodically scan PLABs (for some profiling stuff I was working on) and in G1 some PLABs were unparseable because the length field of arrays could be incorrect (even if the PLAB is retired, it's possible that the length field is still incorrect given that other threads might still be working on that array).
The patch to change G1 to do what ParNew / PS also do is very small (and we've had it for a few months in our repo without any issues). Any chance of convincing you to also take it? I should be clear that the patch doesn't fix a correctness issue in G1; the code is correct as is. But it will bring G1 in line with the other two GCs and allow PLAB scanning during GC, if you want to do that...
Tony
-- Tony Printezis | JVM/GC Engineer / VM Team | Twitter
@TonyPrintezis tprintezis at twitter.com
- Previous message (by thread): RFR (XXS): 8033106 Wrong predicate for checking whether the correct amount of symbol table entries have been processed in G1
- Next message (by thread): Small issue with array chunking in G1
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]