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

Method BatchAllocate

tensorflow/core/framework/ev_allocator.h:515–523  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

513 }
514
515 size_t BatchAllocate(size_t num, size_t num_bytes, void **ret) {
516 auto it = t_bins_.find(num_bytes);
517 if (it != t_bins_.end()) {
518 return it->second->BatchAllocate(num, ret);
519 }
520 auto b = new ThreadLocalBin<ChunkType>(num_bytes, page_map_, arena_);
521 t_bins_.emplace(num_bytes, b);
522 return b->BatchAllocate(num, ret);
523 }
524
525 void Deallocate(size_t num_bytes, void *ptr) {
526 auto it = t_bins_.find(num_bytes);

Callers

nothing calls this directly

Calls 4

findMethod · 0.45
endMethod · 0.45
BatchAllocateMethod · 0.45
emplaceMethod · 0.45

Tested by

no test coverage detected