uint64_t for size here so objects larger than 4GiB can be created on 32-bit platforms