2
* op: Process a task pool until all tasks have been executed
3
* op: Insert task into task pool
6
Assertions to optimize for:
7
* All tasks are of the same size (or differebt)
8
* All tasks have been inserted before any task is processed
9
* All tasks are sequential (or parallel)
10
* Tasks perform no communication and require no data
11
* Task perform communication, data required specified
12
* Tasks can create other tasks
13
* Data is in memory or disk
16
* Choices of termination detection and signalling
17
-- GA_Sync() style global termination detection
18
-- Wait for global termination of a specific taskpool
19
-- ala split-phase barriers
21
API list (more rough notes to be structured into a specification later):
22
------------------------------------------------------------------------
24
1. Single global counter. Supports atomic read increment (and that is it)
25
-- Identifying the task from the counter done by user
26
-- Termination detection done by user (typically GA_Sync)
28
2. Single global counter with known bound on number of tasks. API would support
29
increment and check whether more tasks exist.
30
-- Identifying the task from the counter done by user
31
-- Termination detection supported by API
33
3. Single global counter backing a task iterator.
34
-- Task created by the API from the iterator
35
-- Termination detection by API
37
4. Single global counter backing a global list of tasks
39
5. 2-3 with global counters in multiple processes. 1 does not make sense without
40
allowing repeated task execution. When backing an iterator, the iterator can be
43
6. Distributed tasks queues with work stealing. tasks are integers.
45
7. Distributed task queues with work stealing. all tasks of the same size
47
8. Distributed task queues with work stealing. tasks of different sizes.