MCPcopy Create free account
hub / github.com/apache/arrow / MakeShared

Method MakeShared

cpp/src/arrow/memory_pool.cc:958–967  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

956 }
957
958 static std::shared_ptr<PoolBuffer> MakeShared(MemoryPool* pool, int64_t alignment) {
959 std::shared_ptr<MemoryManager> mm;
960 if (pool == nullptr) {
961 pool = default_memory_pool();
962 mm = default_cpu_memory_manager();
963 } else {
964 mm = CPUDevice::memory_manager(pool);
965 }
966 return std::make_shared<PoolBuffer>(std::move(mm), pool, alignment);
967 }
968
969 static std::unique_ptr<PoolBuffer> MakeUnique(MemoryPool* pool, int64_t alignment) {
970 std::shared_ptr<MemoryManager> mm;

Callers

nothing calls this directly

Calls 2

default_memory_poolFunction · 0.85

Tested by

no test coverage detected