added lazy computation of path edge hash value