This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: PR target/45946: ICE: in extract_insn, at recog.c:2127 when using _Decimal128 with -Os -fno-omit-frame-pointer


Hi,

pushtd1 is missing.  This patch adds it. OK for 4.4/4.5/trunk?

Thanks.


H.J.
---
gcc/

2010-10-20  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/45946
	* config/i386/i386.md (pushtd1): New.

gcc/testsuite/

2010-10-20  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/45946
	* gcc.target/i386/pr45946.c: New.

diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md
index ae52746..e3966e2 100644
--- a/gcc/config/i386/i386.md
+++ b/gcc/config/i386/i386.md
@@ -1737,6 +1737,14 @@
   "TARGET_AVX"
   "ix86_expand_move (OImode, operands); DONE;")
 
+(define_expand "pushtd1"
+  [(match_operand:TD 0 "register_operand" "")]
+  ""
+{
+  ix86_expand_push (TDmode, operands[0]);
+  DONE;
+})
+
 (define_expand "movti"
   [(set (match_operand:TI 0 "nonimmediate_operand" "")
 	(match_operand:TI 1 "nonimmediate_operand" ""))]
--- /dev/null	2010-10-13 10:55:58.381855970 -0700
+++ gcc/gcc/testsuite/gcc.target/i386/pr45946.c	2010-10-20 10:49:43.624661301 -0700
@@ -0,0 +1,13 @@
+/* { dg-do compile } */
+/* { dg-require-effective-target dfp } */
+/* { dg-options "-O -std=gnu99 -Os -fno-omit-frame-pointer" } */
+
+void
+bar (_Decimal128, _Decimal128, _Decimal128, _Decimal128, _Decimal128,
+     _Decimal128, _Decimal128, _Decimal128, _Decimal128);
+
+void
+foo (void)
+{
+  bar (0, 0, 0, 0, 0, 0, 0, 0, 0);
+}


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]