RFR (S): 8067339: PLAB reallocation might result in failure to allocate object in that recently allocated PLAB
mikael.gerdin at oracle.com
Fri Aug 14 08:42:59 UTC 2015
On 2015-08-14 10:29, Thomas Schatzl wrote:
> Hi all,
> can I have reviews for the following small fix: if G1 reallocates a
> PLAB for an object of size X, it allocates a new PLAB of size Y.
> PLABs are required to contain enough space for the object plus some
> alignment reserve; so if X >= Y - alignment-reserve, G1 failed to
> allocate this object it just allocated the PLAB for into that PLAB,
> resulting in an evacuation failure although there is actually enough
> As far as I know this has been a rare occurrence until now because
> current PLAB sizing tended to maximize PLAB sizes, and it is rare to
> have such large objects, but with future changes that actually try to
> size the PLABs so that the expected waste is kept, I noticed a few cases
> of that issue occurring. So this needs to be fixed.
> The fix is to consider the required alignment reserve in the PLAB
> allocation request.
> This is a day one G1 bug.
Looks good to me.
> JPRT, vm.gc testlist, lots of testing.
Lots of testing sounds excellent :)
More information about the hotspot-gc-dev