MCPcopy Create free account
hub / github.com/AMReX-Codes/amrex / Finish

Method Finish

Src/Base/AMReX_BackgroundThread.cpp:52–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50}
51
52void BackgroundThread::Finish ()
53{
54 if (m_thread) {
55 Submit([this] () { m_clearing = true; });
56 std::unique_lock<std::mutex> lck(m_mutx);
57 m_done_cond.wait(lck, [this] () -> bool { return m_func.empty(); });
58 m_clearing = false;
59 lck.unlock();
60 }
61}
62
63}

Callers 1

FinishFunction · 0.80

Calls 4

SubmitFunction · 0.85
unlockMethod · 0.80
waitMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected