This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Remove test for volatile SSA_NAME in scev


SSA_NAMEs can never be volatile.  We don't even expose volatile
variables to the optimizers (neither in real nor virtual operands).


Diego.


	* tree-scalar-evolution.c (analyzable_condition): Remove
	superfluous TREE_THIS_VOLATILE checks on SSA_NAMEs.

Index: tree-scalar-evolution.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree-scalar-evolution.c,v
retrieving revision 2.12
diff -d -c -p -u -r2.12 tree-scalar-evolution.c
--- tree-scalar-evolution.c	11 Nov 2004 20:12:34 -0000	2.12
+++ tree-scalar-evolution.c	12 Nov 2004 13:11:15 -0000
@@ -959,9 +959,6 @@ analyzable_condition (tree expr)
   switch (TREE_CODE (condition))
     {
     case SSA_NAME:
-      /* Volatile expressions are not analyzable.  */
-      if (TREE_THIS_VOLATILE (SSA_NAME_VAR (condition)))
-	return false;
       return true;
       
     case LT_EXPR:
@@ -970,22 +967,7 @@ analyzable_condition (tree expr)
     case GE_EXPR:
     case EQ_EXPR:
     case NE_EXPR:
-      {
-	tree opnd0, opnd1;
-	
-	opnd0 = TREE_OPERAND (condition, 0);
-	opnd1 = TREE_OPERAND (condition, 1);
-	
-	if (TREE_CODE (opnd0) == SSA_NAME
-	    && TREE_THIS_VOLATILE (SSA_NAME_VAR (opnd0)))
-	  return false;
-	
-	if (TREE_CODE (opnd1) == SSA_NAME
-	    && TREE_THIS_VOLATILE (SSA_NAME_VAR (opnd1)))
-	  return false;
-	
-	return true;
-      }
+      return true;
       
     default:
       return false;



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]