Add a clarifying comment; NFC

PiperOrigin-RevId: 323632239
Change-Id: Ia6c34d90e2c446eedd1a3fee1000951a70c955b8
This commit is contained in:
Sanjoy Das 2020-07-28 12:44:25 -07:00 committed by TensorFlower Gardener
parent cdac4cf5c5
commit 3ad158c7b9

View File

@ -118,6 +118,9 @@ class RedzoneAllocator : public ScratchAllocator {
// isn't necessarily just first.size() - 2 * redzone_size_ because when the
// user allocation size is not a multiple of 4 bytes, we round up the size of
// the RHS redzone.
//
// ScratchAllocators need to free all allocated memory on destruction so we
// use `OwningDeviceMemory` here.
std::vector<std::pair<OwningDeviceMemory, int64>> allocated_buffers_;
int64 allocated_bytes_excluding_redzones_ = 0;