Prune redundant output.