replaced the current join algorithm with the new one.

The current version may be faster than the new. we might use both
depending on the situation. So we keep the current one with
commented out.