MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / Drop

Method Drop

tensorflow/core/common_runtime/scoped_allocator_mgr.cc:86–97  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84}
85
86void ScopedAllocatorContainer::Drop(int32 scope_id, ScopedAllocator* sa) {
87 VLOG(2) << "Drop " << scope_id << " from container " << this << " step "
88 << step_id_ << " on " << mgr_->device_name();
89 mutex_lock l(mu_);
90 auto it = allocators_.find(scope_id);
91 if (it != allocators_.end()) {
92 if (it->second.field_index != ScopedAllocator::kBackingIndex) {
93 it->second.instance->DropFromTable();
94 }
95 allocators_.erase(it);
96 }
97}
98
99ScopedAllocatorContainer::~ScopedAllocatorContainer() {
100 VLOG(2) << "~ScopedAllocatorContainer " << this << " step " << step_id_

Callers 1

AllocateRawMethod · 0.45

Calls 5

DropFromTableMethod · 0.80
device_nameMethod · 0.45
findMethod · 0.45
endMethod · 0.45
eraseMethod · 0.45

Tested by

no test coverage detected