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

Method BatchDeallocate

tensorflow/core/framework/ev_allocator.h:395–409  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

393 }
394
395 void BatchDeallocate(size_t bin_size, std::vector<void*>& ptrs) {
396 Bin<ChunkType> *bin = nullptr;
397 {
398 mutex_lock l(mu_);
399 auto it = bins_.find(bin_size);
400 if (it == bins_.end()) {
401 bin = new Bin<ChunkType>(bin_size, page_map_);
402 bins_.emplace(bin_size, bin);
403 } else {
404 bin = it->second;
405 }
406 }
407
408 return bin->BatchDeallocate(ptrs);
409 }
410
411 private:
412 mutex mu_;

Callers

nothing calls this directly

Calls 4

findMethod · 0.45
endMethod · 0.45
emplaceMethod · 0.45
BatchDeallocateMethod · 0.45

Tested by

no test coverage detected