MCPcopy Create free account
hub / github.com/catboost/catboost / ClearLPQueue

Method ClearLPQueue

library/cpp/threading/local_executor/local_executor.cpp:334–347  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

332}
333
334void NPar::TLocalExecutor::ClearLPQueue() {
335 for (bool cont = true; cont;) {
336 cont = false;
337 TSingleJob job;
338 while (Impl_->LowJobQueue.Dequeue(&job)) {
339 --Impl_->LPQueueSize;
340 cont = true;
341 }
342 while (Impl_->MedJobQueue.Dequeue(&job)) {
343 --Impl_->MPQueueSize;
344 cont = true;
345 }
346 }
347}
348
349int NPar::TLocalExecutor::GetQueueSize() const noexcept {
350 return Impl_->QueueSize.load();

Callers 2

StopMethod · 0.80
RunSlaveFunction · 0.80

Calls 1

DequeueMethod · 0.45

Tested by

no test coverage detected