MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / ~TaskExecutor

Method ~TaskExecutor

dnn/test/common/task_executor.cpp:210–224  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

208}
209
210CpuDispatchChecker::TaskExecutor::~TaskExecutor() {
211#if MEGDNN_ENABLE_MULTI_THREADS
212 m_stop = true;
213 for (auto& worker : m_workers) {
214 worker.join();
215 }
216 for (auto flag : m_workers_flag) {
217 delete flag;
218 }
219 if (m_main_thread_affinity) {
220 //! Restore the main thread affinity.
221 MEGDNN_MARK_USED_VAR(do_set_cpu_affinity(m_main_thread_prev_affinity_mask));
222 }
223#endif
224}
225
226// vim: syntax=cpp.doxygen

Callers

nothing calls this directly

Calls 2

do_set_cpu_affinityFunction · 0.85
joinMethod · 0.80

Tested by

no test coverage detected