]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* config/h8300/h8300.md: Add comments about peephole2's.
authorKazu Hirata <kazu@cs.umass.edu>
Sun, 29 Feb 2004 19:18:37 +0000 (19:18 +0000)
committerKazu Hirata <kazu@gcc.gnu.org>
Sun, 29 Feb 2004 19:18:37 +0000 (19:18 +0000)
From-SVN: r78667

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

index 9d17775c7cc97652acf85f168ed24adb266c8af5..c778e5ae27c43aad4980a2ec7659078169fd07fc 100644 (file)
@@ -1,3 +1,7 @@
+2004-02-29  Kazu Hirata  <kazu@cs.umass.edu>
+
+       * config/h8300/h8300.md: Add comments about peephole2's.
+
 2004-02-29  Kazu Hirata  <kazu@cs.umass.edu>
 
        * config/h8300/h8300.md: Tweak operand numbers of some
index 2f3448188d1892ea125178a3c18b6d3f3414baae..eede39193bd466ad61355275b3349490e7e3e9fb 100644 (file)
      }
    operands[4] = GEN_INT (exact_log2 (INTVAL (operands[1]) + 1));")
 
+;; Transform
+;;
+;;     cmp.w   #1,r0
+;;     bhi     .L1
+;;
+;; into
+;;
+;;     shar.w  r0
+;;     bne     .L1
+
+;; TODO: Split the above peephole2.
+
 ;; Transform
 ;;
 ;;     cmp.w   #255,r0
        break;
      }")
 
+;; Transform
+;;
+;;     cmp.w   #255,r0
+;;     bhi     .L1
+;;
+;; into
+;;
+;;     mov.b   r0h,r0h
+;;     bne     .L1
+
+;; TODO: Split the above peephole2.
+
 ;; (compare (reg:SI) (const_int)) takes 6 bytes, so we try to achieve
 ;; the equivalent with shorter sequences.  Here is the summary.  Cases
 ;; are grouped for each define_peephole2.
      }
    operands[5] = GEN_INT (exact_log2 (INTVAL (operands[1]) + 1));")
 
+;; Transform
+;;
+;;     cmp.l   #1,er0
+;;     bhi     .L1
+;;
+;; into
+;;
+;;     mov.l   er0,er1
+;;     shar.l  er1
+;;     bne     .L1
+
+;; TODO: Split the above peephole2.
+
 ;; Transform
 ;;
 ;;     cmp.l   #1,er0
      }
    operands[4] = GEN_INT (exact_log2 (INTVAL (operands[1]) + 1));")
 
+;; Transform
+;;
+;;     cmp.l   #1,er0
+;;     bhi     .L1
+;;
+;; into
+;;
+;;     shar.l  er0
+;;     bne     .L1
+
+;; TODO: Split the above peephole2.
+
 ;; Transform
 ;;
 ;;     cmp.l   #15,er0
      }
    operands[4] = GEN_INT (~INTVAL (operands[1]));")
 
+;; Transform
+;;
+;;     cmp.l   #15,er0
+;;     bhi     .L1
+;;
+;; into
+;;
+;;     and     #240,r0l
+;;     mov.l   er0,er0
+;;     bne     .L1
+
+;; TODO: Split the above peephole2.
+
 ;; Transform
 ;;
 ;;     cmp.l   #65535,er0
        break;
      }")
 
+;; Transform
+;;
+;;     cmp.l   #65535,er0
+;;     bhi     .L1
+;;
+;; into
+;;
+;;     mov.l   e0,e0
+;;     bne     .L1
+
+;; TODO: Split the above peephole2.
+
 ;; For constants like -1, -2, 1, 2, it is still cheaper to make a copy
 ;; of the register being tested, do the subtraction on the copy, and
 ;; then test the copy.  We avoid this transformation if we see more