MCPcopy Create free account
hub / github.com/facebook/CacheLib / provisionPool

Method provisionPool

cachelib/allocator/memory/MemoryPoolManager.cpp:130–136  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

128}
129
130bool MemoryPoolManager::provisionPool(
131 PoolId pid, const std::vector<uint32_t>& slabsDistribution) {
132 if (pid >= static_cast<PoolId>(pools_.size())) {
133 throw std::invalid_argument(fmt::format("Invalid pool id {}", pid));
134 }
135 return pools_[pid]->provision(slabsDistribution);
136}
137
138MemoryPool& MemoryPoolManager::getPoolByName(std::string_view name) const {
139 std::shared_lock l(lock_);

Callers 2

testProvisionPoolMethod · 0.45

Calls 2

provisionMethod · 0.80
sizeMethod · 0.45

Tested by 2

testProvisionPoolMethod · 0.36