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

Method MakeShared

cpp/src/arrow/memory_pool.cc:963–972  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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

Callers

nothing calls this directly

Calls 2

default_memory_poolFunction · 0.85

Tested by

no test coverage detected