new control block 1:
fork, parallel, or some other name. Maybe it does not even need a name?
in simplest form, it would have one input tab at the top and at least two tab receivers at the bottom. Creates two threads that will execute simultaneously until they fall off of their respective stacks or hit "join" control block.
a more advanced form would be a block that has one tab on top, one tab receiver on the bottom, and the same tab on the right and left (maybe a vertical sinusoid type shape?) These blocks are stacked side by side. The more blocks side by side, the more threads.
new control block 2:
join, wait for all, or some other name
It would be nice to have wait for none, wait for all or wait for first,
It might actually be easier to implement this more like the loop blocks so it could nest around the parallel threads. An implementation like this would also elimante the need for the fork block. The top section of the multi action could start with 2 solid tab receivers numbered 1 and 2 and have a ghost tab receiver on the right for 3. As a block is connected to the ghost tab receiver, the ghost becomes solid and a new ghost is formed to the right.
The top row of the nesting block could be "do all" and the bottom row of the nesting block could be wait for none, wait for all, or wait for 1,n where n is the number of threaded blocks. Maybe even have this list for 4 parallel threads:
wait for none
wait for all
wait for list, where list would be entered. example:1,2,4 would wait for those threads to finish but let 3 finish in its own time. Validation: can not wait on a thread stack that contains a forever style block.
Some similar constructs might be hackable with messages, but the concepts would not be so crystal clear.
Offline