(expand_decl): Don't set RTX_UNCHANGING_P.
authorRichard Stallman <rms@gnu.org>
Fri, 14 May 1993 19:00:45 +0000 (19:00 +0000)
committerRichard Stallman <rms@gnu.org>
Fri, 14 May 1993 19:00:45 +0000 (19:00 +0000)
From-SVN: r4457

gcc/stmt.c

index 4400f614a4850ce525986329fd80c97b2d4dc8c1..05b0738f551b38e5896ce7adc60a53f0bfdfc05e 100644 (file)
@@ -2995,8 +2995,15 @@ expand_decl (decl)
 
   if (TREE_THIS_VOLATILE (decl))
     MEM_VOLATILE_P (DECL_RTL (decl)) = 1;
+#if 0 /* A variable is not necessarily unchanging
+        just because it is const.  RTX_UNCHANGING_P
+        means no change in the function,
+        not merely no change in the variable's scope.
+        It is correct to set RTX_UNCHANGING_P if the variable's scope
+        is the whole function.  There's no convenient way to test that.  */
   if (TREE_READONLY (decl))
     RTX_UNCHANGING_P (DECL_RTL (decl)) = 1;
+#endif
 
   /* If doing stupid register allocation, make sure life of any
      register variable starts here, at the start of its scope.  */