------- Additional Comments From pinskia at gcc dot gnu dot org  2004-12-19 
05:22 -------
This patch fixes it but I don't know if it is the correct fix, I have not 
bootstrapped it yet but it works as it 
removes the constraint when not to add SAVE_EXPR around the expression:
Index: tree.c
===============================================================
====
RCS file: /cvs/gcc/gcc/gcc/tree.c,v
retrieving revision 1.457
diff -u -p -r1.457 tree.c
--- tree.c      17 Dec 2004 08:17:01 -0000      1.457
+++ tree.c      19 Dec 2004 05:21:23 -0000
@@ -1669,7 +1669,6 @@ save_expr (tree expr)
   inner = skip_simple_arithmetic (t);
 
   if (TREE_INVARIANT (inner)
-      || (TREE_READONLY (inner) && ! TREE_SIDE_EFFECTS (inner))
       || TREE_CODE (inner) == SAVE_EXPR
       || TREE_CODE (inner) == ERROR_MARK)
     return t;

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18067

Reply via email to