diff --git a/bench/simple/Blocks.hs b/bench/simple/Blocks.hs
--- a/bench/simple/Blocks.hs
+++ b/bench/simple/Blocks.hs
@@ -46,12 +46,12 @@
  where initial n = fill n >>= unsafeWrite arr n >> when (n > 0) (initial $ n - 1)
 {-# INLINE initialize #-}
 
-speedTest :: (Unbox e) => Int
+speedTest :: (Unbox e) => MVector RealWorld e
+                       -> Int
                        -> (Int -> IO e)
                        -> (MVector RealWorld e -> IO ())
                        -> IO Integer
-speedTest n fill algo = do
-  arr <- new n
+speedTest arr n fill algo = do
   initialize arr n fill
   t0 <- clock
   algo arr
diff --git a/bench/simple/Main.hs b/bench/simple/Main.hs
--- a/bench/simple/Main.hs
+++ b/bench/simple/Main.hs
@@ -47,13 +47,14 @@
 
 sortSuite :: String -> GenIO -> Int -> (MVector RealWorld Int -> IO ()) -> IO ()
 sortSuite str g n sort = do
+  arr <- new n
   putStrLn $ "Testing: " ++ str
-  run "Random            " $ speedTest n (rand g >=> modulo n) sort
-  run "Sorted            " $ speedTest n ascend sort
-  run "Reverse-sorted    " $ speedTest n (descend n) sort
-  run "Random duplicates " $ speedTest n (rand g >=> modulo 1000) sort
+  run "Random            " $ speedTest arr n (rand g >=> modulo n) sort
+  run "Sorted            " $ speedTest arr n ascend sort
+  run "Reverse-sorted    " $ speedTest arr n (descend n) sort
+  run "Random duplicates " $ speedTest arr n (rand g >=> modulo 1000) sort
   let m = 4 * (n `div` 4)
-  run "Median killer     " $ speedTest m (medianKiller m) sort
+  run "Median killer     " $ speedTest arr m (medianKiller m) sort
 
 partialSortSuite :: String -> GenIO -> Int -> Int
                  -> (MVector RealWorld Int -> Int -> IO ()) -> IO ()
diff --git a/src/Data/Vector/Algorithms/Merge.hs b/src/Data/Vector/Algorithms/Merge.hs
--- a/src/Data/Vector/Algorithms/Merge.hs
+++ b/src/Data/Vector/Algorithms/Merge.hs
@@ -39,15 +39,22 @@
 
 -- | Sorts an array using a custom comparison.
 sortBy :: (PrimMonad m, MVector v e) => Comparison e -> v (PrimState m) e -> m ()
-sortBy cmp vec
-  | len <= 1  = return ()
-  | len == 2  = O.sort2ByOffset cmp vec 0
-  | len == 3  = O.sort3ByOffset cmp vec 0
-  | len == 4  = O.sort4ByOffset cmp vec 0
-  | otherwise = do buf <- new len
-                   mergeSortWithBuf cmp vec buf
+sortBy cmp vec = if len <= 4
+                    then if len <= 2
+                            then if len /= 2
+                                    then return ()
+                                    else O.sort2ByOffset cmp vec 0
+                            else if len == 3
+                                    then O.sort3ByOffset cmp vec 0
+                                    else O.sort4ByOffset cmp vec 0
+                    else if len < threshold
+                            then I.sortByBounds cmp vec 0 len
+                            else do buf <- new halfLen
+                                    mergeSortWithBuf cmp vec buf
  where
- len = length vec
+ len     = length vec
+ -- odd lengths have a larger half that needs to fit, so use ceiling, not floor
+ halfLen = (len + 1) `div` 2
 {-# INLINE sortBy #-}
 
 mergeSortWithBuf :: (PrimMonad m, MVector v e)
diff --git a/tests/properties/Properties.hs b/tests/properties/Properties.hs
--- a/tests/properties/Properties.hs
+++ b/tests/properties/Properties.hs
@@ -27,7 +27,7 @@
 
 import qualified Data.Map as M
 
-import Test.QuickCheck
+import Test.QuickCheck hiding (Sorted)
 
 import Util
 
@@ -104,7 +104,7 @@
                           in V.all (\(e', i') -> e < e' || i < i') (V.tail arr)
                             .&. stable (V.tail arr)
 
-prop_stable_radix :: (forall e s mv. G.MVector mv e => Int -> Int -> (Int -> e -> Int) 
+prop_stable_radix :: (forall e s mv. G.MVector mv e => Int -> Int -> (Int -> e -> Int)
                         -> mv s e -> ST s ())
                   -> Vector Int -> Property
 prop_stable_radix algo arr =
@@ -113,7 +113,7 @@
  where
  ix = V.fromList [1 .. V.length arr]
  e = V.head arr
- 
+
 prop_optimal :: Int
              -> (forall e s mv. G.MVector mv e => Comparison e -> mv s e -> Int -> ST s ())
              -> Property
@@ -137,7 +137,7 @@
 
 prop_permutation :: (Ord e) => (forall s mv. G.MVector mv e => mv s e -> ST s ())
                  -> Vector e -> Property
-prop_permutation algo arr = property $ 
+prop_permutation algo arr = property $
                             toBag arr == toBag (modify algo arr)
 
 newtype SortedVec e = Sorted (Vector e)
diff --git a/vector-algorithms.cabal b/vector-algorithms.cabal
--- a/vector-algorithms.cabal
+++ b/vector-algorithms.cabal
@@ -1,5 +1,5 @@
 name:              vector-algorithms
-version:           0.8.0.0
+version:           0.8.0.1
 license:           BSD3
 license-file:      LICENSE
 author:            Dan Doel
@@ -139,7 +139,7 @@
       base,
       bytestring,
       containers,
-      QuickCheck > 2.9 && < 2.12,
+      QuickCheck > 2.9 && < 2.13,
       vector,
       vector-algorithms
 
