aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKazu Hirata <kazu@cs.umass.edu>2003-04-02 21:43:35 +0000
committerKazu Hirata <kazu@gcc.gnu.org>2003-04-02 21:43:35 +0000
commit8fc9a7ba7b2f94550dcc912b917d7429ea1f081f (patch)
tree9de7417b0228b036232aa7b65b047123d324e8fe
parent496e1c4bdf3fdd04766aad7013ae8d63b7dcdf0e (diff)
downloadgcc-8fc9a7ba7b2f94550dcc912b917d7429ea1f081f.zip
gcc-8fc9a7ba7b2f94550dcc912b917d7429ea1f081f.tar.gz
gcc-8fc9a7ba7b2f94550dcc912b917d7429ea1f081f.tar.bz2
* config/h8300/h8300.md (a peephole2): Tighten the condition.
From-SVN: r65174
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/config/h8300/h8300.md14
2 files changed, 15 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d7f2b95..bfbcc94 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2003-04-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/h8300/h8300.md (a peephole2): Tighten the condition.
+
2003-04-02 Richard Henderson <rth@redhat.com>
* longlong.h (umul_ppmm) [alpha]: Use __builtin_alpha_umulh.
diff --git a/gcc/config/h8300/h8300.md b/gcc/config/h8300/h8300.md
index 4b54543..a4c76f9 100644
--- a/gcc/config/h8300/h8300.md
+++ b/gcc/config/h8300/h8300.md
@@ -4308,7 +4308,16 @@
gen_rtx_EQ (VOIDmode, cc0_rtx, const0_rtx));
operands[5] = GEN_INT (exact_log2 (INTVAL (operands[1]) + 1));")
-;; Transform A <= 1 to (A & 0xfffffffe) == 0.
+;; Transform
+;;
+;; cmp.l #15,er0
+;; bhi .L1
+;;
+;; into
+;;
+;; and #240,r0l
+;; mov.l er0,er0
+;; bne .L1
(define_peephole2
[(set (cc0)
@@ -4321,8 +4330,7 @@
(pc)))]
"(TARGET_H8300H || TARGET_H8300S)
&& peep2_reg_dead_p (1, operands[0])
- && (INTVAL (operands[1]) == 1
- || INTVAL (operands[1]) == 3
+ && ((TARGET_H8300H && INTVAL (operands[1]) == 3)
|| INTVAL (operands[1]) == 7
|| INTVAL (operands[1]) == 15
|| INTVAL (operands[1]) == 31