Skip to content

Commit 6a6d433

Browse files
author
Yi Wang
committed
Update block parent-kid relationship
1 parent 03a02d6 commit 6a6d433

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

doc/design/concurrent_programming.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ message ProgramDesc {
8383
}
8484
8585
block[1] = Block {
86+
parent = 0,
8687
vars = [x, y, index],
8788
ops = [
8889
slice(input = [X, index], output = x) # index is initialized by parallel_for
@@ -121,6 +122,7 @@ An explanation of the above program:
121122
2. creates `len(L)` threads by calling into the `ThreadPool` singleton, each thread
122123
1. creates an Executor instance, and
123124
2. calls `Executor.Run(block)`, where `block` is block 1 as explained above.
125+
1. Please be aware that block 1 is a sub-block of block 0, so ops in block 1 could refer to variables defined in block 0.
124126

125127
### The Worker Program
126128

0 commit comments

Comments
 (0)