[SPARK-4797] Replace breezeSquaredDistance

This PR replaces slow breezeSquaredDistance. A simple calculation involving 40000 squared distances between the vectors of 20000 dims shows:

* breezeSquaredDistance:  ~12 secs
* This PR: ~10.5 secs


.intersect does not know that the indices are sorted, so it may be much faster to compute the intersection explicitly.  That is done in BLAS.dot; I would recommend following that pattern.  That will keep you from having 3 separate iterations over the indices.

In general, I wonder if these methods would be much faster if you iterated over counters & used while loops, rather than built-in iterator methods like intersect/diff/foreach.