aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1994-11-18 19:16:06 -0500
committerRichard Kenner <kenner@gcc.gnu.org>1994-11-18 19:16:06 -0500
commit4c70a4f326ab0cf1bffe0464fa655fc78c2d8a1d (patch)
tree0f9c6b4fe07f46d8148b87f9a88a12dc42b264ad
parent35068b435fb8c09fff2cbc4eb8a3e1dd904aae0e (diff)
downloadgcc-4c70a4f326ab0cf1bffe0464fa655fc78c2d8a1d.zip
gcc-4c70a4f326ab0cf1bffe0464fa655fc78c2d8a1d.tar.gz
gcc-4c70a4f326ab0cf1bffe0464fa655fc78c2d8a1d.tar.bz2
(peepholes for two DF load/store): New peepholes.
From-SVN: r8517
-rw-r--r--gcc/config/rs6000/rs6000.md24
1 files changed, 24 insertions, 0 deletions
diff --git a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md
index a11f756..e6c2e71 100644
--- a/gcc/config/rs6000/rs6000.md
+++ b/gcc/config/rs6000/rs6000.md
@@ -4436,6 +4436,30 @@
"@
stfdux %3,%0,%2
stfdu %3,%2(%0)")
+
+;; Peephole to convert two consecutive FP loads or stores into lfq/stfq.
+
+(define_peephole
+ [(set (match_operand:DF 0 "gpc_reg_operand" "=f")
+ (match_operand:DF 1 "memory_operand" ""))
+ (set (match_operand:DF 2 "gpc_reg_operand" "=f")
+ (match_operand:DF 3 "memory_operand" ""))]
+ "TARGET_POWER2
+ && registers_ok_for_quad_peep (operands[0], operands[2])
+ && ! MEM_VOLATILE_P (operands[1]) && ! MEM_VOLATILE_P (operands[3])
+ && addrs_ok_for_quad_peep (XEXP (operands[1], 0), XEXP (operands[3], 0))"
+ "lfq%U1%X1 %0,%1")
+
+(define_peephole
+ [(set (match_operand:DF 0 "memory_operand" "")
+ (match_operand:DF 1 "gpc_reg_operand" "f"))
+ (set (match_operand:DF 2 "memory_operand" "")
+ (match_operand:DF 3 "gpc_reg_operand" "f"))]
+ "TARGET_POWER2
+ && registers_ok_for_quad_peep (operands[1], operands[3])
+ && ! MEM_VOLATILE_P (operands[0]) && ! MEM_VOLATILE_P (operands[2])
+ && addrs_ok_for_quad_peep (XEXP (operands[0], 0), XEXP (operands[2], 0))"
+ "stfq%U0%X0 %1,%0")
;; Next come insns related to the calling sequence.
;;