MCPcopy Create free account
hub / github.com/ChunelFeng/CGraph / waitRunTask

Function waitRunTask

src/UtilsCtrl/ThreadPool/Thread/UThreadSecondary.h:95–100  ·  view source on GitHub ↗

* 有等待的执行任务 * @param ms * @return * @notice 目的是降低cpu的占用率 */

Source from the content-addressed store, hash-verified

93 * @notice 目的是降低cpu的占用率
94 */
95 CVoid waitRunTask(const CMSec ms) {
96 const auto& task = pool_task_queue_->popWithTimeout(ms);
97 if (task) {
98 runTask(*task);
99 }
100 }
101
102
103 /**

Callers 2

processTaskFunction · 0.85
processTasksFunction · 0.85

Calls 1

runTaskFunction · 0.85

Tested by

no test coverage detected