Patchwork [ARM-Embedded-4_7/Commit] Disable -fira-hoist-pressure on Thumb2

login
register
mail settings
Submitter Bin Cheng
Date Nov. 30, 2012, 6:05 a.m.
Message ID <003201cdcec0$af94f530$0ebedf90$@cheng@arm.com>
Download mbox | patch
Permalink /patch/202869/
State New
Headers show

Comments

Bin Cheng - Nov. 30, 2012, 6:05 a.m.
Hi,
I committed the patch disabling "-fira-hoist-pressure" on Thumb2 to ARM
Embedded-4_7 branch as r193979.

Thanks.

gcc/ChangeLog.arm
2012-11-30  Bin Cheng  <bin.cheng@arm.com>

	* config/arm/arm.c (arm_option_override): Disable option
	-fira-hoist-pressure on Thumb2.

gcc/testsuite/ChangeLog.arm
2012-11-30  Bin Cheng  <bin.cheng@arm.com>

	* gcc.dg/hoist-register-pressure.c: Skip on ARM Thumb2.
	* gcc.dg/hoist-register-pressure-3.c: Ditto.

Patch

Index: gcc/testsuite/ChangeLog.arm
===================================================================
--- gcc/testsuite/ChangeLog.arm	(revision 193978)
+++ gcc/testsuite/ChangeLog.arm	(revision 193979)
@@ -1,3 +1,8 @@ 
+2012-11-30  Bin Cheng  <bin.cheng@arm.com>
+
+	* gcc.dg/hoist-register-pressure.c: Skip on ARM Thumb2.
+	* gcc.dg/hoist-register-pressure-3.c: Ditto.
+
 2012-11-23  Bin Cheng  <bin.cheng@arm.com>
 
 	Backport from mainline r193687
Index: gcc/testsuite/gcc.dg/hoist-register-pressure.c
===================================================================
--- gcc/testsuite/gcc.dg/hoist-register-pressure.c	(revision 193978)
+++ gcc/testsuite/gcc.dg/hoist-register-pressure.c	(revision 193979)
@@ -1,5 +1,6 @@ 
 /* { dg-options "-Os -fdump-rtl-hoist" }  */
-/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression" "hoist" } } */
+/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression" "hoist" { target { ! arm_thumb2 } } } } */
+/* { dg-final { cleanup-rtl-dump "hoist" } } */
 
 #define BUF 100
 int a[BUF];
Index: gcc/testsuite/gcc.dg/hoist-register-pressure-3.c
===================================================================
--- gcc/testsuite/gcc.dg/hoist-register-pressure-3.c	(revision 193978)
+++ gcc/testsuite/gcc.dg/hoist-register-pressure-3.c	(revision 193979)
@@ -1,5 +1,6 @@ 
 /* { dg-options "-Os -fdump-rtl-hoist" }  */
-/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression" "hoist" } } */
+/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression" "hoist" { target { ! arm_thumb2 } } } } */
+/* { dg-final { cleanup-rtl-dump "hoist" } } */
 
 #define BUF 100
 int a[BUF];
Index: gcc/ChangeLog.arm
===================================================================
--- gcc/ChangeLog.arm	(revision 193978)
+++ gcc/ChangeLog.arm	(revision 193979)
@@ -1,3 +1,8 @@ 
+2012-11-30  Bin Cheng  <bin.cheng@arm.com>
+
+	* config/arm/arm.c (arm_option_override): Disable option
+	-fira-hoist-pressure on Thumb2.
+
 2012-11-28  Bin Cheng  <bin.cheng@arm.com>
 
 	Backport from mainline r193841
Index: gcc/config/arm/arm.c
===================================================================
--- gcc/config/arm/arm.c	(revision 193978)
+++ gcc/config/arm/arm.c	(revision 193979)
@@ -2035,6 +2035,12 @@ 
   else
     max_insns_skipped = current_tune->max_insns_skipped;
 
+  if (TARGET_THUMB2 && flag_ira_hoist_pressure)
+    {
+      /* Don't do register pressure directed hoist on Thumb2.  */
+      flag_ira_hoist_pressure = 0;
+    }
+
   /* Hot/Cold partitioning is not currently supported, since we can't
      handle literal pool placement in that case.  */
   if (flag_reorder_blocks_and_partition)