The current TLAB logging is not completely correct for G1. The logging in ThreadLocalAllocBuffer::print_stats() expects that the allocated size is:
size_t alloc = _number_of_refills * _desired_size;
This is not true since the last tlab in each region might have a different size due to not being allowed to span a region boundary. Fixing this could be done by adding a new value that is updated along with _number_of_refills which counts the actual size allocated.
size_t alloc = _number_of_refills * _desired_size;
This is not true since the last tlab in each region might have a different size due to not being allowed to span a region boundary. Fixing this could be done by adding a new value that is updated along with _number_of_refills which counts the actual size allocated.