]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
rs6000.md (ctr{s,d}i_internal?): Add earlyclobber for MEM case.
authorDavid Edelsohn <edelsohn@gnu.org>
Tue, 1 Jul 2003 19:07:40 +0000 (19:07 +0000)
committerDavid Edelsohn <dje@gcc.gnu.org>
Tue, 1 Jul 2003 19:07:40 +0000 (15:07 -0400)
        * config/rs6000/rs6000.md (ctr{s,d}i_internal?): Add earlyclobber
        for MEM case.

Co-Authored-By: J"orn Rennecke <joern.rennecke@superh.com>
From-SVN: r68788

gcc/ChangeLog
gcc/config/rs6000/rs6000.md

index f846aebf69cce154a4aa3c00f02c52af6bb59d3e..ecba222dc4c99c8ab1dabfb26e4d10ce6a75a4ff 100644 (file)
@@ -1,3 +1,9 @@
+2003-07-01  David Edelsohn  <edelsohn@gnu.org>
+           J"orn Rennecke <joern.rennecke@superh.com>
+
+       * config/rs6000/rs6000.md (ctr{s,d}i_internal?): Add earlyclobber
+       for MEM case.
+
 2003-07-01  Devang Patel  <dpatel@apple.com>
 
        * dbxout.c (DBXOUT_DECR_NESTING): Emit pending bincls, if required.
index 1e891f1f441c1ca426908fb65cb643f62c0a6917..cb50e7e8ab865a3ac4c8641728f0ce7130969c9f 100644 (file)
 
 (define_insn "*ctrsi_internal1"
   [(set (pc)
-       (if_then_else (ne (match_operand:SI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ne (match_operand:SI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (label_ref (match_operand 0 "" ""))
                      (pc)))
-   (set (match_operand:SI 2 "register_operand" "=1,*r,m*q*c*l")
+   (set (match_operand:SI 2 "register_operand" "=1,*r,m,*q*c*l")
        (plus:SI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:SI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:SI 4 "=X,X,&r,r"))]
   "! TARGET_POWERPC64"
   "*
 {
     return \"bdz $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrsi_internal2"
   [(set (pc)
-       (if_then_else (ne (match_operand:SI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ne (match_operand:SI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (pc)
                      (label_ref (match_operand 0 "" ""))))
-   (set (match_operand:SI 2 "register_operand" "=1,*r,m*q*c*l")
+   (set (match_operand:SI 2 "register_operand" "=1,*r,m,*q*c*l")
        (plus:SI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:SI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:SI 4 "=X,X,&r,r"))]
   "! TARGET_POWERPC64"
   "*
 {
     return \"{bdn|bdnz} $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrdi_internal1"
   [(set (pc)
-       (if_then_else (ne (match_operand:DI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ne (match_operand:DI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (label_ref (match_operand 0 "" ""))
                      (pc)))
-   (set (match_operand:DI 2 "register_operand" "=1,*r,m*c*l")
+   (set (match_operand:DI 2 "register_operand" "=1,*r,m,*c*l")
        (plus:DI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:DI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:DI 4 "=X,X,&r,r"))]
   "TARGET_POWERPC64"
   "*
 {
     return \"bdz $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrdi_internal2"
   [(set (pc)
-       (if_then_else (ne (match_operand:DI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ne (match_operand:DI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (pc)
                      (label_ref (match_operand 0 "" ""))))
-   (set (match_operand:DI 2 "register_operand" "=1,*r,m*c*l")
+   (set (match_operand:DI 2 "register_operand" "=1,*r,m,*c*l")
        (plus:DI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:DI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:DI 4 "=X,X,&r,r"))]
   "TARGET_POWERPC64"
   "*
 {
     return \"{bdn|bdnz} $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 ;; Similar, but we can use GE since we have a REG_NONNEG.
 
 (define_insn "*ctrsi_internal3"
   [(set (pc)
-       (if_then_else (ge (match_operand:SI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ge (match_operand:SI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 0))
                      (label_ref (match_operand 0 "" ""))
                      (pc)))
-   (set (match_operand:SI 2 "register_operand" "=1,*r,m*q*c*l")
+   (set (match_operand:SI 2 "register_operand" "=1,*r,m,*q*c*l")
        (plus:SI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&X"))
-   (clobber (match_scratch:SI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:SI 4 "=X,X,&r,r"))]
   "! TARGET_POWERPC64 && find_reg_note (insn, REG_NONNEG, 0)"
   "*
 {
     return \"bdz $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrsi_internal4"
   [(set (pc)
-       (if_then_else (ge (match_operand:SI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ge (match_operand:SI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 0))
                      (pc)
                      (label_ref (match_operand 0 "" ""))))
-   (set (match_operand:SI 2 "register_operand" "=1,*r,m*q*c*l")
+   (set (match_operand:SI 2 "register_operand" "=1,*r,m,*q*c*l")
        (plus:SI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&X"))
-   (clobber (match_scratch:SI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:SI 4 "=X,X,&r,r"))]
   "! TARGET_POWERPC64 && find_reg_note (insn, REG_NONNEG, 0)"
   "*
 {
     return \"{bdn|bdnz} $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrdi_internal3"
   [(set (pc)
-       (if_then_else (ge (match_operand:DI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ge (match_operand:DI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 0))
                      (label_ref (match_operand 0 "" ""))
                      (pc)))
-   (set (match_operand:DI 2 "register_operand" "=1,*r,m*c*l")
+   (set (match_operand:DI 2 "register_operand" "=1,*r,m,*c*l")
        (plus:DI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:DI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:DI 4 "=X,X,&r,r"))]
   "TARGET_POWERPC64 && find_reg_note (insn, REG_NONNEG, 0)"
   "*
 {
     return \"bdz $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrdi_internal4"
   [(set (pc)
-       (if_then_else (ge (match_operand:DI 1 "register_operand" "c,*r,*r")
+       (if_then_else (ge (match_operand:DI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 0))
                      (pc)
                      (label_ref (match_operand 0 "" ""))))
-   (set (match_operand:DI 2 "register_operand" "=1,*r,m*c*l")
+   (set (match_operand:DI 2 "register_operand" "=1,*r,m,*c*l")
        (plus:DI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:DI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:DI 4 "=X,X,&r,r"))]
   "TARGET_POWERPC64 && find_reg_note (insn, REG_NONNEG, 0)"
   "*
 {
     return \"{bdn|bdnz} $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 ;; Similar but use EQ
 
 (define_insn "*ctrsi_internal5"
   [(set (pc)
-       (if_then_else (eq (match_operand:SI 1 "register_operand" "c,*r,*r")
+       (if_then_else (eq (match_operand:SI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (label_ref (match_operand 0 "" ""))
                      (pc)))
-   (set (match_operand:SI 2 "register_operand" "=1,*r,m*q*c*l")
+   (set (match_operand:SI 2 "register_operand" "=1,*r,m,*q*c*l")
        (plus:SI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:SI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:SI 4 "=X,X,&r,r"))]
   "! TARGET_POWERPC64"
   "*
 {
     return \"{bdn|bdnz} $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrsi_internal6"
   [(set (pc)
-       (if_then_else (eq (match_operand:SI 1 "register_operand" "c,*r,*r")
+       (if_then_else (eq (match_operand:SI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (pc)
                      (label_ref (match_operand 0 "" ""))))
-   (set (match_operand:SI 2 "register_operand" "=1,*r,m*q*c*l")
+   (set (match_operand:SI 2 "register_operand" "=1,*r,m,*q*c*l")
        (plus:SI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:SI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:SI 4 "=X,X,&r,r"))]
   "! TARGET_POWERPC64"
   "*
 {
     return \"bdz $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrdi_internal5"
   [(set (pc)
-       (if_then_else (eq (match_operand:DI 1 "register_operand" "c,*r,*r")
+       (if_then_else (eq (match_operand:DI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (label_ref (match_operand 0 "" ""))
                      (pc)))
-   (set (match_operand:DI 2 "register_operand" "=1,*r,m*c*l")
+   (set (match_operand:DI 2 "register_operand" "=1,*r,m,*c*l")
        (plus:DI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:DI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:DI 4 "=X,X,&r,r"))]
   "TARGET_POWERPC64"
   "*
 {
     return \"{bdn|bdnz} $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 (define_insn "*ctrdi_internal6"
   [(set (pc)
-       (if_then_else (eq (match_operand:DI 1 "register_operand" "c,*r,*r")
+       (if_then_else (eq (match_operand:DI 1 "register_operand" "c,*r,*r,*r")
                          (const_int 1))
                      (pc)
                      (label_ref (match_operand 0 "" ""))))
-   (set (match_operand:DI 2 "register_operand" "=1,*r,m*c*l")
+   (set (match_operand:DI 2 "register_operand" "=1,*r,m,*c*l")
        (plus:DI (match_dup 1)
                 (const_int -1)))
-   (clobber (match_scratch:CC 3 "=X,&x,&x"))
-   (clobber (match_scratch:DI 4 "=X,X,r"))]
+   (clobber (match_scratch:CC 3 "=X,&x,&x,&x"))
+   (clobber (match_scratch:DI 4 "=X,X,&r,r"))]
   "TARGET_POWERPC64"
   "*
 {
     return \"bdz $+8\;b %l0\";
 }"
   [(set_attr "type" "branch")
-   (set_attr "length" "4,12,16")])
+   (set_attr "length" "4,12,16,16")])
 
 ;; Now the splitters if we could not allocate the CTR register