summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2010-05-31 21:42:07 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2010-05-31 21:42:07 +0200
commitc71ad61ee029c7c75d75f8af9f7c9f1356e21656 (patch)
treec1e27d52a9eb51354b87f069a491976123819610
parent4585cf723650a3e5632649a52b354041c57e860d (diff)
downloadgcc-c71ad61ee029c7c75d75f8af9f7c9f1356e21656.tar.gz
re PR target/44338 (-mno-fused-madd causes FAIL: gcc.target/i386/sse-23.c (internal compiler error))
PR target/44338 * config/i386/sse.md (fma4i_fmadd<mode>4256, fma4i_fmsub<mode>4256, fma4i_fnmadd<mode>4256, fma4i_fnmsub<mode>4256, fma4i_fmadd<mode>4, fma4i_fmsub<mode>4, fma4i_fnmadd<mode>4, fma4i_fnmsub<mode>4, fma4i_vmfmadd<mode>4, fma4i_vmfmsub<mode>4, fma4i_vmfnmadd<mode>4, fma4i_vmfnmsub<mode>4, fma4i_fmaddsubv8sf4, fma4i_fmaddsubv4df4, fma4i_fmaddsubv4sf4, fma4i_fmaddsubv2df4, fma4i_fmsubaddv8sf4, fma4i_fmsubaddv4df4, fma4i_fmsubaddv4sf4, fma4i_fmsubaddv2df4): Guard only with TARGET_FMA4 instead of TARGET_FMA4 && TARGET_FUSED_MADD. * gcc.target/i386/sse-24.c: New test. From-SVN: r160083
-rw-r--r--gcc/ChangeLog13
-rw-r--r--gcc/config/i386/sse.md40
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gcc.target/i386/sse-24.c5
4 files changed, 43 insertions, 20 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index ae7aa9aa55d..5e3110b51ea 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,16 @@
+2010-05-31 Jakub Jelinek <jakub@redhat.com>
+
+ PR target/44338
+ * config/i386/sse.md (fma4i_fmadd<mode>4256, fma4i_fmsub<mode>4256,
+ fma4i_fnmadd<mode>4256, fma4i_fnmsub<mode>4256, fma4i_fmadd<mode>4,
+ fma4i_fmsub<mode>4, fma4i_fnmadd<mode>4, fma4i_fnmsub<mode>4,
+ fma4i_vmfmadd<mode>4, fma4i_vmfmsub<mode>4, fma4i_vmfnmadd<mode>4,
+ fma4i_vmfnmsub<mode>4, fma4i_fmaddsubv8sf4, fma4i_fmaddsubv4df4,
+ fma4i_fmaddsubv4sf4, fma4i_fmaddsubv2df4, fma4i_fmsubaddv8sf4,
+ fma4i_fmsubaddv4df4, fma4i_fmsubaddv4sf4, fma4i_fmsubaddv2df4):
+ Guard only with TARGET_FMA4 instead of TARGET_FMA4 &&
+ TARGET_FUSED_MADD.
+
2010-05-31 Jan Hubicka <jh@suse.cz>
* tree.h (tree_range_check_failed): Declare noreturn.
diff --git a/gcc/config/i386/sse.md b/gcc/config/i386/sse.md
index d028bd3940b..d154f073b05 100644
--- a/gcc/config/i386/sse.md
+++ b/gcc/config/i386/sse.md
@@ -1943,7 +1943,7 @@
(match_operand:FMA4MODEF4 2 "nonimmediate_operand" "x,m"))
(match_operand:FMA4MODEF4 3 "nonimmediate_operand" "xm,x"))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmadd<fma4modesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -1957,7 +1957,7 @@
(match_operand:FMA4MODEF4 2 "nonimmediate_operand" "x,m"))
(match_operand:FMA4MODEF4 3 "nonimmediate_operand" "xm,x"))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsub<fma4modesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -1971,7 +1971,7 @@
(match_operand:FMA4MODEF4 1 "nonimmediate_operand" "%x,x")
(match_operand:FMA4MODEF4 2 "nonimmediate_operand" "x,m")))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfnmadd<fma4modesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -1986,7 +1986,7 @@
(match_operand:FMA4MODEF4 2 "nonimmediate_operand" "x,m"))
(match_operand:FMA4MODEF4 3 "nonimmediate_operand" "xm,x"))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfnmsub<fma4modesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -2000,7 +2000,7 @@
(match_operand:SSEMODEF2P 2 "nonimmediate_operand" "x,m"))
(match_operand:SSEMODEF2P 3 "nonimmediate_operand" "xm,x"))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmadd<ssemodesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -2014,7 +2014,7 @@
(match_operand:SSEMODEF2P 2 "nonimmediate_operand" "x,m"))
(match_operand:SSEMODEF2P 3 "nonimmediate_operand" "xm,x"))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsub<ssemodesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -2028,7 +2028,7 @@
(match_operand:SSEMODEF2P 1 "nonimmediate_operand" "%x,x")
(match_operand:SSEMODEF2P 2 "nonimmediate_operand" "x,m")))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfnmadd<ssemodesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -2043,7 +2043,7 @@
(match_operand:SSEMODEF2P 2 "nonimmediate_operand" "x,m"))
(match_operand:SSEMODEF2P 3 "nonimmediate_operand" "xm,x"))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfnmsub<ssemodesuffixf4>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<MODE>")])
@@ -2062,7 +2062,7 @@
(match_dup 0)
(const_int 1))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmadd<ssemodesuffixf2s>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<ssescalarmode>")])
@@ -2079,7 +2079,7 @@
(match_dup 0)
(const_int 1))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsub<ssemodesuffixf2s>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<ssescalarmode>")])
@@ -2096,7 +2096,7 @@
(match_dup 0)
(const_int 1))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfnmadd<ssemodesuffixf2s>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<ssescalarmode>")])
@@ -2114,7 +2114,7 @@
(match_dup 0)
(const_int 1))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfnmsub<ssemodesuffixf2s>\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "<ssescalarmode>")])
@@ -2293,7 +2293,7 @@
(match_dup 3))
(const_int 170))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmaddsubps\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V8SF")])
@@ -2314,7 +2314,7 @@
(match_dup 3))
(const_int 10))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmaddsubpd\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V4DF")])
@@ -2335,7 +2335,7 @@
(match_dup 3))
(const_int 10))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmaddsubps\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V4SF")])
@@ -2356,7 +2356,7 @@
(match_dup 3))
(const_int 2))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmaddsubpd\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V2DF")])
@@ -2377,7 +2377,7 @@
(match_dup 3))
(const_int 85))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsubaddps\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V8SF")])
@@ -2398,7 +2398,7 @@
(match_dup 3))
(const_int 5))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsubaddpd\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V4DF")])
@@ -2419,7 +2419,7 @@
(match_dup 3))
(const_int 5))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsubaddps\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V4SF")])
@@ -2440,7 +2440,7 @@
(match_dup 3))
(const_int 1))]
UNSPEC_FMA4_INTRINSIC))]
- "TARGET_FMA4 && TARGET_FUSED_MADD"
+ "TARGET_FMA4"
"vfmsubaddpd\t{%3, %2, %1, %0|%0, %1, %2, %3}"
[(set_attr "type" "ssemuladd")
(set_attr "mode" "V2DF")])
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 48e9cc7c88a..b4ed8e2c8fd 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2010-05-31 Jakub Jelinek <jakub@redhat.com>
+
+ PR target/44338
+ * gcc.target/i386/sse-24.c: New test.
+
2010-05-31 Jan Hubicka <jh@suse.cz>
* gcc.dg/builtin-apply4.c: Compile with -Wmissing-return.
diff --git a/gcc/testsuite/gcc.target/i386/sse-24.c b/gcc/testsuite/gcc.target/i386/sse-24.c
new file mode 100644
index 00000000000..d18b08e977d
--- /dev/null
+++ b/gcc/testsuite/gcc.target/i386/sse-24.c
@@ -0,0 +1,5 @@
+/* PR target/44338 */
+/* { dg-do compile } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -march=k8 -mno-fused-madd" } */
+
+#include "sse-23.c"