]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* config/h8300/h8300.md (a peephole2): New.
authorKazu Hirata <kazu@cs.umass.edu>
Mon, 24 Mar 2003 14:17:49 +0000 (14:17 +0000)
committerKazu Hirata <kazu@gcc.gnu.org>
Mon, 24 Mar 2003 14:17:49 +0000 (14:17 +0000)
From-SVN: r64802

gcc/ChangeLog
gcc/config/h8300/h8300.md

index d079df824393cef7d9230f22f8567c4b52e4532a..e560e073ff6b18c15d14873f50cc5726ac2e9261 100644 (file)
@@ -1,3 +1,7 @@
+2003-03-24  Kazu Hirata  <kazu@cs.umass.edu>
+
+       * config/h8300/h8300.md (a peephole2): New.
+
 2003-03-24  Jakub Jelinek  <jakub@redhat.com>
 
        * dojump.c (do_jump): Handle UNSAVE_EXPR specially.
index 883fa5c3e2dc8d5c1cbbda9e8b9ea90e0f25860a..43bca1083e805116d0260cc6760dbf97d389a8ea 100644 (file)
                  ? gen_rtx_GE (VOIDmode, cc0_rtx, const0_rtx)
                  : gen_rtx_LT (VOIDmode, cc0_rtx, const0_rtx));")
 
+(define_peephole2
+  [(set (match_operand:QI 0 "register_operand" "")
+       (match_operand:QI 1 "general_operand" ""))
+   (set (match_operand:SI 2 "register_operand" "")
+       (and:SI (match_dup 2)
+               (const_int 255)))]
+  "(TARGET_H8300H || TARGET_H8300S)
+   && !reg_overlap_mentioned_p (operands[2], operands[1])
+   && REGNO (operands[0]) == REGNO (operands[2])"
+  [(set (match_dup 2)
+       (const_int 0))
+   (set (strict_low_part (match_dup 0))
+       (match_dup 1))]
+  "")
+
 (define_peephole2
   [(set (match_operand:SI 0 "register_operand" "")
        (match_operand:SI 1 "general_operand" ""))