Fix rans ec_multisymbol merge issues.

The rans experiment is dead. The ans experiment with the ec_multisymbol
experiment also turned on takes its place.

Change-Id: Ie9f30ec7cf73aae6b2ea580a7b1f208485a8a7a7
diff --git a/aom_dsp/bitreader.h b/aom_dsp/bitreader.h
index 478945b..6121273 100644
--- a/aom_dsp/bitreader.h
+++ b/aom_dsp/bitreader.h
@@ -211,7 +211,7 @@
 static INLINE int aom_read_symbol_(aom_reader *r, aom_cdf_prob *cdf,
                                    int nsymbs ACCT_STR_PARAM) {
   int ret;
-#if CONFIG_RANS
+#if CONFIG_ANS
   (void)nsymbs;
   ret = rans_read(r, cdf);
 #elif CONFIG_DAALA_EC
diff --git a/aom_dsp/bitwriter.h b/aom_dsp/bitwriter.h
index f96bf90..78ddc08 100644
--- a/aom_dsp/bitwriter.h
+++ b/aom_dsp/bitwriter.h
@@ -173,7 +173,7 @@
 #if CONFIG_EC_MULTISYMBOL
 static INLINE void aom_write_symbol(aom_writer *w, int symb, aom_cdf_prob *cdf,
                                     int nsymbs) {
-#if CONFIG_RANS
+#if CONFIG_ANS
   struct rans_sym s;
   (void)nsymbs;
   assert(cdf);
diff --git a/av1/common/entropy.c b/av1/common/entropy.c
index 95368c6..bfb3058 100644
--- a/av1/common/entropy.c
+++ b/av1/common/entropy.c
@@ -2807,7 +2807,7 @@
   extend_to_full_distribution(&full[UNCONSTRAINED_NODES], model[PIVOT_NODE]);
 }
 
-#if CONFIG_RANS || CONFIG_DAALA_EC
+#if CONFIG_EC_MULTISYMBOL
 static void build_token_cdfs(const aom_prob *pdf_model,
                              aom_cdf_prob cdf[ENTROPY_TOKENS]) {
   int i, sum = 0;
@@ -2828,7 +2828,7 @@
             build_token_cdfs(fc->coef_probs[t][i][j][k][l],
                              fc->coef_cdfs[t][i][j][k][l]);
 }
-#endif  // CONFIG_RANS
+#endif  // CONFIG_EC_MULTISYMBOL
 
 void av1_default_coef_probs(AV1_COMMON *cm) {
 #if CONFIG_ENTROPY
@@ -2844,9 +2844,9 @@
   av1_copy(cm->fc->coef_probs[TX_16X16], default_coef_probs_16x16);
   av1_copy(cm->fc->coef_probs[TX_32X32], default_coef_probs_32x32);
 #endif  // CONFIG_ENTROPY
-#if CONFIG_RANS || CONFIG_DAALA_EC
+#if CONFIG_EC_MULTISYMBOL
   av1_coef_pareto_cdfs(cm->fc);
-#endif  // CONFIG_RANS
+#endif  // CONFIG_EC_MULTISYMBOL
 }
 
 #if CONFIG_ADAPT_SCAN
diff --git a/av1/common/entropy.h b/av1/common/entropy.h
index 55ed8d4..6a8832f 100644
--- a/av1/common/entropy.h
+++ b/av1/common/entropy.h
@@ -263,11 +263,6 @@
   return combine_entropy_contexts(above_ec, left_ec);
 }
 
-#if CONFIG_RANS
-struct frame_contexts;
-void av1_coef_pareto_cdfs(struct frame_contexts *fc);
-#endif  // CONFIG_RANS
-
 #if CONFIG_ENTROPY
 #define COEF_COUNT_SAT_BITS 5
 #define COEF_MAX_UPDATE_FACTOR_BITS 7
diff --git a/av1/encoder/bitstream.c b/av1/encoder/bitstream.c
index 9111cb7..338b663 100644
--- a/av1/encoder/bitstream.c
+++ b/av1/encoder/bitstream.c
@@ -1789,11 +1789,9 @@
   MODE_INFO *m;
   int plane;
   int bh, bw;
-#if CONFIG_RANS
-  (void)tok;
-  (void)tok_end;
-  (void)plane;
-#endif  // !CONFIG_RANS
+#if CONFIG_RD_DEBUG
+  int64_t txb_coeff_cost[MAX_MB_PLANE] = { 0 };
+#endif
 #if CONFIG_PVQ
   MB_MODE_INFO *mbmi;
   BLOCK_SIZE bsize;
@@ -2738,9 +2736,9 @@
   const TX_MODE tx_mode = cpi->common.tx_mode;
   const TX_SIZE max_tx_size = tx_mode_to_biggest_tx_size[tx_mode];
   TX_SIZE tx_size;
-#if CONFIG_RANS
+#if CONFIG_EC_MULTISYMBOL
   int update = 0;
-#endif  // CONFIG_RANS
+#endif  // CONFIG_EC_MULTISYMBOL
 #if CONFIG_ENTROPY
   AV1_COMMON *cm = &cpi->common;
   SUBFRAME_STATS *subframe_stats = &cpi->subframe_stats;
@@ -2788,18 +2786,18 @@
 
         update_coef_probs_subframe(w, cpi, tx_size, cpi->branch_ct_buf,
                                    frame_coef_probs);
-#if CONFIG_RANS
+#if CONFIG_EC_MULTISYMBOL
         update = 1;
-#endif  // CONFIG_RANS
+#endif  // CONFIG_EC_MULTISYMBOL
       } else {
 #endif  // CONFIG_ENTROPY
         build_tree_distribution(cpi, tx_size, frame_branch_ct,
                                 frame_coef_probs);
         update_coef_probs_common(w, cpi, tx_size, frame_branch_ct,
                                  frame_coef_probs);
-#if CONFIG_RANS
+#if CONFIG_EC_MULTISYMBOL
         update = 1;
-#endif  // CONFIG_RANS
+#endif  // CONFIG_EC_MULTISYMBOL
 #if CONFIG_ENTROPY
       }
 #endif  // CONFIG_ENTROPY
@@ -2826,9 +2824,9 @@
     av1_copy(cm->counts.eob_branch, eob_counts_copy);
   }
 #endif  // CONFIG_ENTROPY
-#if CONFIG_RANS
+#if CONFIG_EC_MULTISYMBOL
   if (update) av1_coef_pareto_cdfs(cpi->common.fc);
-#endif  // CONFIG_RANS
+#endif  // CONFIG_EC_MULTISYMBOL
 }
 #endif
 
diff --git a/av1/encoder/tokenize.c b/av1/encoder/tokenize.c
index 5aafa79..73f63d3 100644
--- a/av1/encoder/tokenize.c
+++ b/av1/encoder/tokenize.c
@@ -306,12 +306,12 @@
 };
 #endif
 
-#if !CONFIG_RANS
+#if !CONFIG_EC_MULTISYMBOL
 const struct av1_token av1_coef_encodings[ENTROPY_TOKENS] = {
   { 2, 2 },  { 6, 3 },   { 28, 5 },  { 58, 6 },  { 59, 6 },  { 60, 6 },
   { 61, 6 }, { 124, 7 }, { 125, 7 }, { 126, 7 }, { 127, 7 }, { 0, 1 }
 };
-#endif  // !CONFIG_RANS
+#endif  // !CONFIG_EC_MULTISYMBOL
 
 struct tokenize_b_args {
   const AV1_COMP *cpi;
diff --git a/av1/encoder/tokenize.h b/av1/encoder/tokenize.h
index 27bdef5..e44bcc7 100644
--- a/av1/encoder/tokenize.h
+++ b/av1/encoder/tokenize.h
@@ -46,9 +46,9 @@
 
 extern const aom_tree_index av1_coef_tree[];
 extern const aom_tree_index av1_coef_con_tree[];
-#if !CONFIG_RANS
+#if !CONFIG_EC_MULTISYMBOL
 extern const struct av1_token av1_coef_encodings[];
-#endif  // !CONFIG_RANS
+#endif  // !CONFIG_EC_MULTISYMBOL
 
 int av1_is_skippable_in_plane(MACROBLOCK *x, BLOCK_SIZE bsize, int plane);
 int av1_has_high_freq_in_plane(MACROBLOCK *x, BLOCK_SIZE bsize, int plane);
diff --git a/configure b/configure
index 75a8844..e3391d1 100755
--- a/configure
+++ b/configure
@@ -271,7 +271,6 @@
     new_quant
     supertx
     ans
-    rans
     ec_multisymbol
     loop_restoration
     ext_partition