tasklets.hh
Go to the documentation of this file.
234 std::cerr << "ERROR: Uncaught std::exception when running tasklet: " << e.what() << ". Trying to continue.\n";
237 std::cerr << "ERROR: Uncaught exception (general type) when running tasklet. Trying to continue.\n";
333 std::cerr << "ERROR: Uncaught std::exception when running tasklet: " << e.what() << ". Trying to continue.\n";
A simple tasklet that runs a function that returns void and does not take any arguments a given numbe... Definition: tasklets.hh:71 FunctionRunnerTasklet(int numInvocations, const Fn &fn) Definition: tasklets.hh:74 FunctionRunnerTasklet(const FunctionRunnerTasklet &)=default virtual void run()=0 int workerThreadIndex() const Returns the index of the current worker thread. Definition: tasklets.hh:206 int numWorkerThreads() const Returns the number of worker threads for the tasklet runner. Definition: tasklets.hh:216 void run_() do the work until the queue received an end tasklet Definition: tasklets.hh:295 std::condition_variable workAvailableCondition_ Definition: tasklets.hh:344 void barrier() Make sure that all tasklets have been completed after this method has been called. Definition: tasklets.hh:270 std::shared_ptr< FunctionRunnerTasklet< Fn > > dispatchFunction(Fn &fn, int numInvocations=1) Convenience method to construct a new function runner tasklet and dispatch it immediately. Definition: tasklets.hh:259 void dispatch(std::shared_ptr< TaskletInterface > tasklet) Add a new tasklet. Definition: tasklets.hh:224 TaskletRunner(unsigned numWorkers) Creates a tasklet runner with numWorkers underling threads for doing work. Definition: tasklets.hh:174 static void startWorkerThread_(TaskletRunner *taskletRunner, int workerThreadIndex) Definition: tasklets.hh:286 std::vector< std::unique_ptr< std::thread > > threads_ Definition: tasklets.hh:341 TaskletRunner(const TaskletRunner &)=delete std::queue< std::shared_ptr< TaskletInterface > > taskletQueue_ Definition: tasklets.hh:342 Definition: blackoilboundaryratevector.hh:37 Definition: tasklets.hh:93 static thread_local TaskletRunner * taskletRunner_ Definition: tasklets.hh:94 static thread_local int workerThreadIndex_ Definition: tasklets.hh:95 |