parallelize the second phase