Description
In function fastSquaredDistance, there is a low performance logic:
the sqDist = Vectors.sqdist(v1, v2) is better than sqDist = sumSquaredNorm - 2.0 * dot(v1, v2) in calculation performance
So get rid of the low performance login in function fastSquaredDistance.
More test(End-to-End, function) situation can be found in https://github.com/apache/spark/pull/22893
Already update a patch #22893 for merge