Add clarity to "Op Name" for device memory allocation that was preallocated and unused.

PiperOrigin-RevId: 350867777
Change-Id: I81ef32c3f11869ce16e9e4cbfebfc2454f208e62
This commit is contained in:
Yi Situ 2021-01-08 17:50:19 -08:00 committed by TensorFlower Gardener
parent 987e514e22
commit 5975aae33f

View File

@ -320,11 +320,11 @@ void InsertSpecialAllocations(int64 unmapped_allocation_bytes, int64 step_id,
if (unmapped_allocation_bytes > 0) {
MemoryActivityMetadata* special_allocation =
memory_profile->add_special_allocations();
FillActivityMetadata(
HostEventType::kMemoryAllocation,
{unmapped_allocation_bytes, unmapped_allocation_bytes, 0,
"preallocated/unknown", step_id, "persist/dynamic", 0, "unknown"},
special_allocation);
FillActivityMetadata(HostEventType::kMemoryAllocation,
{unmapped_allocation_bytes, unmapped_allocation_bytes,
0, "unused preallocated device memory", step_id,
"persist/dynamic", 0, "unknown"},
special_allocation);
active_allocs->push_back({--index, special_allocation});
}
int64 stack_bytes =