Keep track of the total serialized size of each layer
Keep track of the total serialized size of each layer (including serialization headers, so it will be slightly larger than the uncompressedSize for uncompressed data).
Keep track of the total serialized size of each layer (including serialization headers, so it will be slightly larger than the uncompressedSize for uncompressed data).