Disable max_issue when scheduling for register pressure
authorMaxim Kuvyrkov <maxim.kuvyrkov@gmail.com>
Fri, 24 Oct 2014 08:22:49 +0000 (08:22 +0000)
committerMaxim Kuvyrkov <mkuvyrkov@gcc.gnu.org>
Fri, 24 Oct 2014 08:22:49 +0000 (08:22 +0000)
* haifa-sched.c (sched_init): Disable max_issue when scheduling for
register pressure.

From-SVN: r216623

gcc/ChangeLog
gcc/haifa-sched.c

index ac5f97baeba66a00e6fc8f483d2296b5f24d1fb0..fa8674601a4bb74a87fbd434ca19c31283f00bcb 100644 (file)
@@ -1,3 +1,8 @@
+2014-10-24  Maxim Kuvyrkov  <maxim.kuvyrkov@gmail.com>
+
+        * haifa-sched.c (sched_init): Disable max_issue when scheduling for
+        register pressure.
+
 2014-10-24  Maxim Kuvyrkov  <maxim.kuvyrkov@gmail.com>
 
         * haifa-sched.c (cached_first_cycle_multipass_dfa_lookahead,)
index b78d6972fe1eeaadaff88f77d0178b69036eb5de..f64f3f59ed93e9fb35ab63cb0a1b66358226a88f 100644 (file)
@@ -6863,7 +6863,10 @@ sched_init (void)
   else
     issue_rate = 1;
 
-  if (targetm.sched.first_cycle_multipass_dfa_lookahead)
+  if (targetm.sched.first_cycle_multipass_dfa_lookahead
+      /* Don't use max_issue with reg_pressure scheduling.  Multipass
+        scheduling and reg_pressure scheduling undo each other's decisions.  */
+      && sched_pressure == SCHED_PRESSURE_NONE)
     dfa_lookahead = targetm.sched.first_cycle_multipass_dfa_lookahead ();
   else
     dfa_lookahead = 0;