Major refactoring to support new features

Convert an ad hoc on-the-fly two pass generator into a
recursive descent parser and code generator.

While at it
- generate code for parallel invocations (untested)
- add support for .| and |. source and sink
- add hooks for code verification
- simplify syntax by making the scatter block the same as the rest

This new design also allows gather commands to appear within the
scatter blog (support needs to be added), allowing the script to
specify a DAG rather than a tree.