5544c1b
From 848750a4acf9ea5c473be596d41720e702d770f0 Mon Sep 17 00:00:00 2001
5544c1b
From: Aurelien Jarno <aurelien@aurel32.net>
5544c1b
Date: Mon, 10 Sep 2012 23:51:42 +0200
5544c1b
Subject: [PATCH] tcg/optimize: remove TCG_TEMP_ANY
5544c1b
5544c1b
TCG_TEMP_ANY has no different meaning than TCG_TEMP_UNDEF, so use
5544c1b
the later instead.
5544c1b
5544c1b
Reviewed-by: Richard Henderson <rth@twiddle.net>
5544c1b
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
5544c1b
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
5544c1b
---
5544c1b
 tcg/optimize.c | 11 +++++------
5544c1b
 1 file changed, 5 insertions(+), 6 deletions(-)
5544c1b
5544c1b
diff --git a/tcg/optimize.c b/tcg/optimize.c
5544c1b
index 1be7631..308b7f9 100644
5544c1b
--- a/tcg/optimize.c
5544c1b
+++ b/tcg/optimize.c
5544c1b
@@ -39,8 +39,7 @@ typedef enum {
5544c1b
     TCG_TEMP_UNDEF = 0,
5544c1b
     TCG_TEMP_CONST,
5544c1b
     TCG_TEMP_COPY,
5544c1b
-    TCG_TEMP_HAS_COPY,
5544c1b
-    TCG_TEMP_ANY
5544c1b
+    TCG_TEMP_HAS_COPY
5544c1b
 } tcg_temp_state;
5544c1b
 
5544c1b
 struct tcg_temp_info {
5544c1b
@@ -52,7 +51,7 @@ struct tcg_temp_info {
5544c1b
 
5544c1b
 static struct tcg_temp_info temps[TCG_MAX_TEMPS];
5544c1b
 
5544c1b
-/* Reset TEMP's state to TCG_TEMP_ANY.  If TEMP was a representative of some
5544c1b
+/* Reset TEMP's state to TCG_TEMP_UNDEF.  If TEMP was a representative of some
5544c1b
    class of equivalent temp's, a new representative should be chosen in this
5544c1b
    class. */
5544c1b
 static void reset_temp(TCGArg temp, int nb_temps, int nb_globals)
5544c1b
@@ -69,7 +68,7 @@ static void reset_temp(TCGArg temp, int nb_temps, int nb_globals)
5544c1b
         }
5544c1b
         for (i = temps[temp].next_copy; i != temp; i = temps[i].next_copy) {
5544c1b
             if (new_base == (TCGArg)-1) {
5544c1b
-                temps[i].state = TCG_TEMP_ANY;
5544c1b
+                temps[i].state = TCG_TEMP_UNDEF;
5544c1b
             } else {
5544c1b
                 temps[i].val = new_base;
5544c1b
             }
5544c1b
@@ -81,9 +80,9 @@ static void reset_temp(TCGArg temp, int nb_temps, int nb_globals)
5544c1b
         temps[temps[temp].prev_copy].next_copy = temps[temp].next_copy;
5544c1b
         new_base = temps[temp].val;
5544c1b
     }
5544c1b
-    temps[temp].state = TCG_TEMP_ANY;
5544c1b
+    temps[temp].state = TCG_TEMP_UNDEF;
5544c1b
     if (new_base != (TCGArg)-1 && temps[new_base].next_copy == new_base) {
5544c1b
-        temps[new_base].state = TCG_TEMP_ANY;
5544c1b
+        temps[new_base].state = TCG_TEMP_UNDEF;
5544c1b
     }
5544c1b
 }
5544c1b