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

Method DoSpawnAdds

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

Source from the content-addressed store, hash-verified

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