Tasks may be executed in parallel to take advantage of the hardware (multi-core) or the environment (distributed builds). By default Waf does not execute immediately the tasks that are ready. Instead, tasks are added to a queue which is consumed by threads. Waf detects the number of installed processors. For uni-processor only one task is executed at a time, for dual-processors two tasks are executed at a time, and so on. To disable task parallelization, use the option -j1. To enhance parallelization, use the option -j with the amount of consumers:
$ waf -j3
By default, Waf does not allow consumer threads to access the tasks directly:
The following illustrates the relationship producer-consumer performed for the builds: