non-recursive in-place mergeSort