use memory to converge on shortest path on reruns