MCPcopy Create free account
hub / github.com/apple/foundationdb / block

Method block

fdbserver/coroimpl/CoroFlow.actor.cpp:101–108  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

99 }
100
101 void block() {
102 // Coro_switchTo_( swapCoro(main_coro), main_coro );
103 blocked = Promise<Void>();
104 double before = now();
105 CoroThreadPool::waitFor(blocked.getFuture());
106 if (g_network->isSimulated() && g_simulator.getCurrentProcess()->rebooting)
107 TraceEvent("CoroUnblocked").detail("After", now() - before);
108 }
109
110 virtual void run() = 0;
111

Callers 5

reachedMethod · 0.45
threadSafetySenderFunction · 0.45
threadSafetyTestFunction · 0.45
threadSafetyTest2Function · 0.45
returnCancelRaceTestFunction · 0.45

Calls 7

nowFunction · 0.85
waitForFunction · 0.85
TraceEventClass · 0.85
getCurrentProcessMethod · 0.80
detailMethod · 0.80
getFutureMethod · 0.45
isSimulatedMethod · 0.45

Tested by 4

threadSafetySenderFunction · 0.36
threadSafetyTestFunction · 0.36
threadSafetyTest2Function · 0.36
returnCancelRaceTestFunction · 0.36