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

Method finish

cachelib/navy/scheduler/ThreadPoolJobQueue.cpp:149–157  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

147}
148
149uint64_t JobQueue::finish() {
150 // Busy wait, but used only in tests
151 std::unique_lock<std::mutex> lock{mutex_};
152 while (processing_ != 0 || !queue_.empty()) {
153 ScopedUnlock<std::mutex> unlock{lock};
154 std::this_thread::yield();
155 }
156 return enqueueCount_;
157}
158
159JobQueue::Stats JobQueue::getStats() const {
160 Stats stats;

Callers 2

TESTFunction · 0.45
TESTFunction · 0.45

Calls 1

emptyMethod · 0.45

Tested by 2

TESTFunction · 0.36
TESTFunction · 0.36