]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
toplev.c (rest_of_handle_cfg): Add reg_scan pass if we're running mark_constant_function.
authorEric Christopher <echristo@redhat.com>
Sat, 10 Jan 2004 06:54:02 +0000 (06:54 +0000)
committerEric Christopher <echristo@gcc.gnu.org>
Sat, 10 Jan 2004 06:54:02 +0000 (06:54 +0000)
2004-01-09  Eric Christopher  <echristo@redhat.com>

* toplev.c (rest_of_handle_cfg): Add reg_scan pass
if we're running mark_constant_function.

From-SVN: r75634

gcc/ChangeLog
gcc/toplev.c

index 5beb07d60fb5284eb9f5ab20f02c14bea527d261..a4756335357687f645c2bbbb7d751bef89cf8079 100644 (file)
@@ -1,3 +1,8 @@
+2004-01-09  Eric Christopher  <echristo@redhat.com>
+
+       * toplev.c (rest_of_handle_cfg): Add reg_scan pass
+       if we're running mark_constant_function.
+
 2004-01-09  Jeff Bailey  <jbailey@nisa.net>
 
        PR target/12561
index 51a5e56722ee15882cfabce5b043f86549f5e9fa..0f6ca26faba73131b390de6aeefa71130f69f6e2 100644 (file)
@@ -835,11 +835,11 @@ int flag_schedule_speculative_load_dangerous = 0;
 
    flag_sched_stalled_insns means that insns can be moved prematurely from the queue
    of stalled insns into the ready list.
-  
+
    flag_sched_stalled_insns_dep controls how many insn groups will be examined
    for a dependency on a stalled insn that is candidate for premature removal
    from the queue of stalled insns into the ready list (has an effect only if
-   the flag 'sched_stalled_insns' is set).  */ 
+   the flag 'sched_stalled_insns' is set).  */
 
 int flag_sched_stalled_insns = 0;
 int flag_sched_stalled_insns_dep = 1;
@@ -1237,12 +1237,12 @@ randomize (void)
     {
       unsigned HOST_WIDE_INT value;
       static char random_seed[HOST_BITS_PER_WIDE_INT / 4 + 3];
-      
+
       /* Get some more or less random data.  */
 #ifdef HAVE_GETTIMEOFDAY
       {
        struct timeval tv;
-       
+
        gettimeofday (&tv, NULL);
        local_tick = tv.tv_sec * 1000 + tv.tv_usec / 1000;
       }
@@ -1255,7 +1255,7 @@ randomize (void)
       }
 #endif
       value = local_tick ^ getpid ();
-      
+
       sprintf (random_seed, HOST_WIDE_INT_PRINT_HEX, value);
       flag_random_seed = random_seed;
     }
@@ -1410,7 +1410,7 @@ output_file_directive (FILE *asm_file, const char *input_name)
 {
   int len;
   const char *na;
-  
+
   if (input_name == NULL)
     input_name = "<stdin>";
 
@@ -2512,7 +2512,12 @@ rest_of_handle_cfg (tree decl, rtx insns)
      life_analysis rarely eliminates modification of external memory.
    */
   if (optimize)
-    mark_constant_function ();
+    {
+      /* Alias analysis depends on this information and mark_constant_function
+       depends on alias analysis.  */
+      reg_scan (insns, max_reg_num (), 1);
+      mark_constant_function ();
+    }
 
   close_dump_file (DFI_cfg, print_rtl_with_bb, insns);
 }
@@ -3061,7 +3066,7 @@ rest_of_compilation (tree decl)
 
   /* Register rtl specific functions for cfg.  */
   rtl_register_cfg_hooks ();
-  
+
   /* Now that we're out of the frontend, we shouldn't have any more
      CONCATs anywhere.  */
   generating_concat_p = 0;
@@ -3629,7 +3634,7 @@ rest_of_compilation (tree decl)
 }
 
 /* Display help for target options.  */
-void 
+void
 display_target_options (void)
 {
   int undoc, i;
@@ -4011,7 +4016,7 @@ default_get_pch_validity (size_t *len)
   size_t i;
 #endif
   char *result, *r;
-  
+
   *len = sizeof (target_flags) + 2;
 #ifdef TARGET_OPTIONS
   for (i = 0; i < ARRAY_SIZE (target_options); i++)
@@ -4028,7 +4033,7 @@ default_get_pch_validity (size_t *len)
   r += 2;
   memcpy (r, &target_flags, sizeof (target_flags));
   r += sizeof (target_flags);
-  
+
 #ifdef TARGET_OPTIONS
   for (i = 0; i < ARRAY_SIZE (target_options); i++)
     {
@@ -4053,7 +4058,7 @@ default_pch_valid_p (const void *data_p, size_t len)
   const char *data = (const char *)data_p;
   const char *flag_that_differs = NULL;
   size_t i;
-  
+
   /* -fpic and -fpie also usually make a PCH invalid.  */
   if (data[0] != flag_pic)
     return _("created and used with different settings of -fpic");
@@ -4084,7 +4089,7 @@ default_pch_valid_p (const void *data_p, size_t len)
     }
   data += sizeof (target_flags);
   len -= sizeof (target_flags);
-  
+
   /* Check string options.  */
 #ifdef TARGET_OPTIONS
   for (i = 0; i < ARRAY_SIZE (target_options); i++)
@@ -4105,7 +4110,7 @@ default_pch_valid_p (const void *data_p, size_t len)
 #endif
 
   return NULL;
-  
+
  make_message:
   {
     char *r;