[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/gsumalo/cpp-taskflow/master/examples/subflow.cpp [Back]  [Original]

// This example demonstrates how to use cpp-taskflow to create
// dynamic workload during execution.
//
// We first create four tasks A, B, C, and D. During the execution
// of B, it uses flow builder to creates another three tasks
// B1, B2, and B3, and adds dependencies from B1 and B2 to B3.
//
// We use dispatch and get to wait until the graph finished.
// Do so is difference from "wait_for_all" which will clean up the
// finished graphs. After the graph finished, we dump the topology
// for inspection.
//
// Usage: ./subflow detach|join
//

#include   

const auto usage = "usage: ./subflow detach|join";

int main(int argc, char* argv[]) {

  if(argc != 2) {
    std::cerr 

Web Proxy Viewer  |  New URL  |  Original Page