aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorDavid Holsgrove <david.holsgrove@xilinx.com>2014-01-30 17:18:17 +0000
committerMichael Eager <eager@gcc.gnu.org>2014-01-30 17:18:17 +0000
commit29bd5728111c90c178fd82ba455c2a686dd02542 (patch)
tree0e8ea99d725ee6af8c42357de7a4d22aff1df343 /gcc
parentc345a0b156755781956c1f866624e1c3224e9a7c (diff)
downloadgcc-29bd5728111c90c178fd82ba455c2a686dd02542.zip
gcc-29bd5728111c90c178fd82ba455c2a686dd02542.tar.gz
gcc-29bd5728111c90c178fd82ba455c2a686dd02542.tar.bz2
Add SImode to comparison operator, prevents ICE during combine
rtl pass with error message; internal compiler error: in simplify_subreg, at simplify-rtx.c:5725 Use ordered_comparison_operator predicate to limit operators to those fcmp can handle, and letting compiler reorder insns to accomodate unordered as necessary gcc/ChangeLog 2013-11-26 David Holsgrove <david.holsgrove@xilinx.com> * config/microblaze/microblaze.md(cstoresf4, cbranchsf4): Replace comparison_operator with ordered_comparison_operator. testsuite/ChangeLog 2014-01-22 David holsgrove <david.holsgrove@xilinx.com> * testsuite/gcc.target/microblaze/isa/fcmp4.c: New file. From-SVN: r207311
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/microblaze/microblaze.md4
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/gcc.target/microblaze/isa/fcmp4.c9
4 files changed, 20 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 802aa47..206648a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2014-01-30 David Holsgrove <david.holsgrove@xilinx.com>
+
+ * config/microblaze/microblaze.md(cstoresf4, cbranchsf4): Replace
+ comparison_operator with ordered_comparison_operator.
+
2014-01-30 Nick Clifton <nickc@redhat.com>
* config/mn10300/mn10300-protos.h (mn10300_store_multiple_operation_p):
diff --git a/gcc/config/microblaze/microblaze.md b/gcc/config/microblaze/microblaze.md
index 367f253..8431f2d 100644
--- a/gcc/config/microblaze/microblaze.md
+++ b/gcc/config/microblaze/microblaze.md
@@ -1650,7 +1650,7 @@
;;----------------------------------------------------------------
(define_insn "cstoresf4"
[(set (match_operand:SI 0 "register_operand" "=r")
- (match_operator 1 "comparison_operator"
+ (match_operator:SI 1 "ordered_comparison_operator"
[(match_operand:SF 2 "register_operand" "r")
(match_operand:SF 3 "register_operand" "r")]))]
"TARGET_HARD_FLOAT"
@@ -1679,7 +1679,7 @@
(define_expand "cbranchsf4"
[(set (pc)
- (if_then_else (match_operator 0 "comparison_operator"
+ (if_then_else (match_operator 0 "ordered_comparison_operator"
[(match_operand:SF 1 "register_operand")
(match_operand:SF 2 "register_operand")])
(label_ref (match_operand 3 ""))
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 5283614..c7b4ef3 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2014-01-30 David Holsgrove <david.holsgrove@xilinx.com>
+
+ * gcc.target/microblaze/isa/fcmp4.c: New.
+
2014-01-30 Marek Polacek <polacek@redhat.com>
PR c/59940
diff --git a/gcc/testsuite/gcc.target/microblaze/isa/fcmp4.c b/gcc/testsuite/gcc.target/microblaze/isa/fcmp4.c
new file mode 100644
index 0000000..79cc5f9
--- /dev/null
+++ b/gcc/testsuite/gcc.target/microblaze/isa/fcmp4.c
@@ -0,0 +1,9 @@
+/* { dg-options "-O3 -mcpu=v6.00.a -mhard-float" } */
+
+void float_func(float f1, float f2, float f3)
+{
+ /* { dg-final { scan-assembler "fcmp\.eq\tr(\[0-9]\|\[1-2]\[0-9]\|3\[0-1]),r(\[0-9]\|\[1-2]\[0-9]\|3\[0-1]),r(\[0-9]\|\[1-2]\[0-9]\|3\[0-1])\[^0-9]" } } */
+ /* { dg-final { scan-assembler "fcmp\.le\tr(\[0-9]\|\[1-2]\[0-9]\|3\[0-1]),r(\[0-9]\|\[1-2]\[0-9]\|3\[0-1]),r(\[0-9]\|\[1-2]\[0-9]\|3\[0-1])\[^0-9]" } } */
+ if(f1==f2 && f1<=f3)
+ print ("f1 eq f2 && f1 le f3");
+}