MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / CountThread

Method CountThread

tensorflow/cc/training/coordinator_test.cc:99–106  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97
98 private:
99 void CountThread(std::atomic<int>* counter, int until, Notification* start) {
100 if (start != nullptr) start->WaitForNotification();
101 while (!coord_->ShouldStop() && counter->load() < until) {
102 (*counter)++;
103 Env::Default()->SleepForMicroseconds(10 * 1000);
104 }
105 coord_->RequestStop().IgnoreError();
106 }
107 void SetStatusThread(const Status& status, BlockingCounter* counter,
108 Notification* start) {
109 start->WaitForNotification();

Callers

nothing calls this directly

Calls 7

DefaultFunction · 0.85
RequestStopMethod · 0.80
WaitForNotificationMethod · 0.45
ShouldStopMethod · 0.45
loadMethod · 0.45
SleepForMicrosecondsMethod · 0.45
IgnoreErrorMethod · 0.45

Tested by

no test coverage detected