Iterative version of chain execution.
Improvements and new helper structures.