Merging benchmarking branch (for milner).

Improved candidate generation heuristics and invariant pruning before communication.