| 107 | } |
| 108 | |
| 109 | absl::optional<AllocatorStats> GPUVMemAllocator::GetStats() { |
| 110 | absl::optional<AllocatorStats> stats = device_allocator_->GetStats(); |
| 111 | absl::optional<AllocatorStats> allocator_stats = host_allocator_->GetStats(); |
| 112 | stats->peak_bytes_in_use += (allocator_stats ? allocator_stats->peak_bytes_in_use : 0); |
| 113 | return stats; |
| 114 | } |
| 115 | |
| 116 | void GPUVMemAllocator::ClearStats() { |
| 117 | device_allocator_->ClearStats(); |
no outgoing calls