Replace DAALA_DIST with MSE in CDEF search

Use DAALA_DIST only when CONFIG_DIST_8X8 is true.

Tested on lowres and midres speed 1(30 frames), coding performance
changes(%):
          psnr    ssim
lowres   -0.07    0.14
midres   -0.11    0.12

STATS_CHANGED

Change-Id: I6f171eb18179dafd650d6408b522493589340461
diff --git a/av1/encoder/pickcdef.c b/av1/encoder/pickcdef.c
index 8064bca..a61fd28 100644
--- a/av1/encoder/pickcdef.c
+++ b/av1/encoder/pickcdef.c
@@ -178,6 +178,7 @@
   }
 }
 
+#if CONFIG_DIST_8X8
 static INLINE uint64_t dist_8x8_16bit(uint16_t *dst, int dstride, uint16_t *src,
                                       int sstride, int coeff_shift) {
   uint64_t svar = 0;
@@ -205,6 +206,7 @@
                (svar + dvar + (400 << 2 * coeff_shift)) /
                (sqrt((20000 << 4 * coeff_shift) + svar * (double)dvar)));
 }
+#endif  // CONFIG_DIST_8X8
 
 static INLINE uint64_t mse_8x8_16bit(uint16_t *dst, int dstride, uint16_t *src,
                                      int sstride) {
@@ -243,8 +245,15 @@
       by = dlist[bi].by;
       bx = dlist[bi].bx;
       if (pli == 0) {
+#if CONFIG_DIST_8X8
         sum += dist_8x8_16bit(&dst[(by << 3) * dstride + (bx << 3)], dstride,
                               &src[bi << (3 + 3)], 8, coeff_shift);
+#else
+
+        sum += mse_8x8_16bit(&dst[(by << 3) * dstride + (bx << 3)], dstride,
+                             &src[bi << (3 + 3)], 8);
+#endif  // CONFIG_DIST_8X8
+
       } else {
         sum += mse_8x8_16bit(&dst[(by << 3) * dstride + (bx << 3)], dstride,
                              &src[bi << (3 + 3)], 8);