improve path computations speed