taskflow / taskflow

A General-purpose Parallel and Heterogeneous Task Programming System

Home Page:https://taskflow.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Determinism in single-threaded mode

Ravbug opened this issue · comments

If I create an executor with

 tf::Executor executor{1};

then give it the same task graph repeatedly, is the order that the tasks run in guaranteed to be the same across each call to .run()? I'm trying to diagnose a potential race condition in my application, which creates a task graph at startup and invokes .run() once per frame.

Yes. If the executor has only one worker, the execution order is deterministic.