diff mbox

Fix PR rtl-optimization/54456

Message ID 201209042103.27190.ebotcazou@adacore.com
State New
Headers show

Commit Message

Eric Botcazou Sept. 4, 2012, 7:03 p.m. UTC
This patch "fixes" PR rtl-optimization/54456 by running the first scheduling 
pass only when optimizing, as is already done for the second scheduling pass.

Tested on x86_64-suse-linux, applied on the mainline.


2012-09-04  Eric Botcazou  <ebotcazou@adacore.com>

	PR rtl-optimization/54456
	* sched-rgn.c (gate_handle_sched): Return 1 only if optimize > 0.
diff mbox

Patch

Index: sched-rgn.c
===================================================================
--- sched-rgn.c	(revision 190863)
+++ sched-rgn.c	(working copy)
@@ -3473,7 +3473,7 @@  static bool
 gate_handle_sched (void)
 {
 #ifdef INSN_SCHEDULING
-  return flag_schedule_insns && dbg_cnt (sched_func);
+  return optimize > 0 && flag_schedule_insns && dbg_cnt (sched_func);
 #else
   return 0;
 #endif