Speed up the algorithm slightly.