MCPcopy Create free account
hub / github.com/apache/arrow / DoSpawnAdds

Method DoSpawnAdds

cpp/src/arrow/util/thread_pool_test.cc:501–515  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

499 }
500
501 void DoSpawnAdds(ThreadPool* pool, int nadds, AddTaskFunc add_func,
502 StopToken stop_token = StopToken::Unstoppable(),
503 StopSource* stop_source = nullptr) {
504 AddTester add_tester(nadds, stop_token);
505 add_tester.SpawnTasks(pool, add_func);
506 if (stop_source) {
507 stop_source->RequestStop();
508 }
509 ASSERT_OK(pool->Shutdown());
510 if (stop_source) {
511 add_tester.CheckNotAllComputed();
512 } else {
513 add_tester.CheckResults();
514 }
515 }
516
517 void SpawnAdds(ThreadPool* pool, int nadds, AddTaskFunc add_func,
518 StopToken stop_token = StopToken::Unstoppable()) {

Callers

nothing calls this directly

Calls 6

UnstoppableFunction · 0.85
SpawnTasksMethod · 0.80
RequestStopMethod · 0.80
CheckNotAllComputedMethod · 0.80
ShutdownMethod · 0.45
CheckResultsMethod · 0.45

Tested by

no test coverage detected