Example 4: Operator replication where threaded ports are not inserted

In this example of user-defined parallelism, all operators except for Src are fused into the same PE.

The parallel transformation replicates operators A and B. The Src operator is given a splitter. Fusion places the Snk operator and operators A and B in one PE. Fusion places the Src operator into its own PE.
composite Comp4(input In; output B) {
  graph
    stream<Type> A = Functor(In) {}
    stream<Type> B = Functor(A) {}
}

composite Main4 {
  graph
    stream<Type> Src = Source() {
      config placement: partitionIsolation;
    }

    @parallel(width=2)
    stream<Type> Out = Comp4(Src) {
      config placement: partitionColocation(“SnkAB”);
    }

    () as Snk = Sink(Out) {
      config placement: partitionColocation(“SnkAB”);
    }
}

The Logical and Physical stream graphs for Example 4.