Commit 65fdd5e9 by Jeff Law Committed by Jeff Law

mn10300.c (mn10300_match_ccmode): Fix where we look for cc setter after the compare-elim changes.

2017-05-12  Jeff Law  <law@redhat.com>
	    Jakub Jelinek  <jakub@redhat.com>

	* config/mn10300/mn10300.c (mn10300_match_ccmode): Fix where
	we look for cc setter after the compare-elim changes.
	* config/mn10300/mn10300.md (addsi3_flags): Fix order of patterns
	within the vector to match what compare-elim now expects.
	(subsi3_flags, andsi3_flags, iorsi3_flags): Likewise.
	(xorsi3_flags, one_cmplsi2_flags): Likewise.

	* config/rx/rx.c (rx_match_ccmode): Fix where we look cc setter
	after the compare-elim changes.
	* config/rx/rx.md (abssi2_flags): Fix order of patterns within
	the vector to match what compare-elim now expects.
	(addsi3_flags, adc_flags, addsi3_flags peepholes): Likewise.
	(andsi3_flags, negsi2_flags, one_cmplsi2_flags): Likewise.
	(iorsi3_flags, rotlsi3_flags, rotrsi3_flags): Likewise.
	(ashrsi3_flags, lshrsi3_flags, ashlsi3_flags): Likewise.
	(ssaddsi3, subsi3_flags, sbb_flags, xorsi3_flags): Likewise.

	* config/visium/visium.c (single_set_and_flags): Fix where
	we look for cc setter after the compare-elim changes.
	* config/visium/visium.md (flags_subst_logic): Fix order of patterns
	with the vector to match what compare-elim now expects.
	(flags_subst_arith, add<mode>3_insn_set_carry): Likewise.
	(add<mode>3_insn_set_overflow, addsi3_insn_set_carry): Likewise.
	(addsi3_insn_set_overflow, sub<mode>3_insn_set_carry): Likewise.
	(sub<mode>3_insn_set_overflow, subsi3_insn_set_carry): Likewise.
	(subsi3_insn_set_overflow, negsi2_insn_set_carry): Likewise.
	(neg<mode>2_insn_set_overflow): Likewise.

Co-Authored-By: Jakub Jelinek <jakub@redhat.com>

From-SVN: r248007
parent c7488b4f
2017-05-12 Jeff Law <law@redhat.com>
Jakub Jelinek <jakub@redhat.com>
* config/mn10300/mn10300.c (mn10300_match_ccmode): Fix where
we look for cc setter after the compare-elim changes.
* config/mn10300/mn10300.md (addsi3_flags): Fix order of patterns
within the vector to match what compare-elim now expects.
(subsi3_flags, andsi3_flags, iorsi3_flags): Likewise.
(xorsi3_flags, one_cmplsi2_flags): Likewise.
* config/rx/rx.c (rx_match_ccmode): Fix where we look cc setter
after the compare-elim changes.
* config/rx/rx.md (abssi2_flags): Fix order of patterns within
the vector to match what compare-elim now expects.
(addsi3_flags, adc_flags, addsi3_flags peepholes): Likewise.
(andsi3_flags, negsi2_flags, one_cmplsi2_flags): Likewise.
(iorsi3_flags, rotlsi3_flags, rotrsi3_flags): Likewise.
(ashrsi3_flags, lshrsi3_flags, ashlsi3_flags): Likewise.
(ssaddsi3, subsi3_flags, sbb_flags, xorsi3_flags): Likewise.
* config/visium/visium.c (single_set_and_flags): Fix where
we look for cc setter after the compare-elim changes.
* config/visium/visium.md (flags_subst_logic): Fix order of patterns
with the vector to match what compare-elim now expects.
(flags_subst_arith, add<mode>3_insn_set_carry): Likewise.
(add<mode>3_insn_set_overflow, addsi3_insn_set_carry): Likewise.
(addsi3_insn_set_overflow, sub<mode>3_insn_set_carry): Likewise.
(sub<mode>3_insn_set_overflow, subsi3_insn_set_carry): Likewise.
(subsi3_insn_set_overflow, negsi2_insn_set_carry): Likewise.
(neg<mode>2_insn_set_overflow): Likewise.
2017-05-12 Jim Wilson <jim.wilson@linaro.org> 2017-05-12 Jim Wilson <jim.wilson@linaro.org>
PR middle-end/79794 PR middle-end/79794
......
...@@ -2895,7 +2895,7 @@ mn10300_match_ccmode (rtx insn, machine_mode cc_mode) ...@@ -2895,7 +2895,7 @@ mn10300_match_ccmode (rtx insn, machine_mode cc_mode)
gcc_checking_assert (XVECLEN (PATTERN (insn), 0) == 2); gcc_checking_assert (XVECLEN (PATTERN (insn), 0) == 2);
op1 = XVECEXP (PATTERN (insn), 0, 1); op1 = XVECEXP (PATTERN (insn), 0, 0);
gcc_checking_assert (GET_CODE (SET_SRC (op1)) == COMPARE); gcc_checking_assert (GET_CODE (SET_SRC (op1)) == COMPARE);
flags = SET_DEST (op1); flags = SET_DEST (op1);
......
...@@ -592,12 +592,12 @@ ...@@ -592,12 +592,12 @@
;; Note that ADD IMM,SP does not set the flags, so omit that here. ;; Note that ADD IMM,SP does not set the flags, so omit that here.
(define_insn "*addsi3_flags" (define_insn "*addsi3_flags"
[(set (match_operand:SI 0 "register_operand" "=r,!r") [(set (reg CC_REG)
(plus:SI (match_operand:SI 1 "register_operand" "%0, r") (compare (plus:SI (match_operand:SI 1 "register_operand" "%0, r")
(match_operand:SI 2 "nonmemory_operand" "ri, r"))) (match_operand:SI 2 "nonmemory_operand" "ri, r"))
(set (reg CC_REG) (const_int 0)))
(compare (plus:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=r,!r")
(const_int 0)))] (plus:SI (match_dup 1) (match_dup 2)))]
"reload_completed && mn10300_match_ccmode (insn, CCZNCmode)" "reload_completed && mn10300_match_ccmode (insn, CCZNCmode)"
{ return mn10300_output_add (operands, true); } { return mn10300_output_add (operands, true); }
[(set_attr "timings" "11,22")] [(set_attr "timings" "11,22")]
...@@ -605,12 +605,12 @@ ...@@ -605,12 +605,12 @@
;; A helper to expand the above, with the CC_MODE filled in. ;; A helper to expand the above, with the CC_MODE filled in.
(define_expand "addsi3_flags" (define_expand "addsi3_flags"
[(parallel [(set (match_operand:SI 0 "register_operand") [(parallel [(set (reg:CCZNC CC_REG)
(plus:SI (match_operand:SI 1 "register_operand")
(match_operand:SI 2 "nonmemory_operand")))
(set (reg:CCZNC CC_REG)
(compare:CCZNC (plus:SI (match_dup 1) (match_dup 2)) (compare:CCZNC (plus:SI (match_dup 1) (match_dup 2))
(const_int 0)))])] (const_int 0)))
(set (match_operand:SI 0 "register_operand")
(plus:SI (match_operand:SI 1 "register_operand")
(match_operand:SI 2 "nonmemory_operand")))])]
"" ""
) )
...@@ -791,12 +791,12 @@ ...@@ -791,12 +791,12 @@
) )
(define_insn "*subsi3_flags" (define_insn "*subsi3_flags"
[(set (match_operand:SI 0 "register_operand" "=r, r") [(set (reg CC_REG)
(minus:SI (match_operand:SI 1 "register_operand" "0, r") (compare (minus:SI (match_operand:SI 1 "register_operand" "0, r")
(match_operand:SI 2 "nonmemory_operand" "ri,r"))) (match_operand:SI 2 "nonmemory_operand" "ri,r"))
(set (reg CC_REG) (const_int 0)))
(compare (minus:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=r, r")
(const_int 0)))] (minus:SI (match_dup 1) (match_dup 2)))]
"reload_completed && mn10300_match_ccmode (insn, CCZNCmode)" "reload_completed && mn10300_match_ccmode (insn, CCZNCmode)"
"@ "@
sub %2,%0 sub %2,%0
...@@ -807,12 +807,12 @@ ...@@ -807,12 +807,12 @@
;; A helper to expand the above, with the CC_MODE filled in. ;; A helper to expand the above, with the CC_MODE filled in.
(define_expand "subsi3_flags" (define_expand "subsi3_flags"
[(parallel [(set (match_operand:SI 0 "register_operand") [(parallel [(set (reg:CCZNC CC_REG)
(minus:SI (match_operand:SI 1 "register_operand")
(match_operand:SI 2 "nonmemory_operand")))
(set (reg:CCZNC CC_REG)
(compare:CCZNC (minus:SI (match_dup 1) (match_dup 2)) (compare:CCZNC (minus:SI (match_dup 1) (match_dup 2))
(const_int 0)))])] (const_int 0)))
(set (match_operand:SI 0 "register_operand")
(minus:SI (match_operand:SI 1 "register_operand")
(match_operand:SI 2 "nonmemory_operand")))])]
"" ""
) )
...@@ -1195,12 +1195,12 @@ ...@@ -1195,12 +1195,12 @@
) )
(define_insn "*andsi3_flags" (define_insn "*andsi3_flags"
[(set (match_operand:SI 0 "register_operand" "=D,D,r") [(set (reg CC_REG)
(and:SI (match_operand:SI 1 "register_operand" "%0,0,r") (compare (and:SI (match_operand:SI 1 "register_operand" "%0,0,r")
(match_operand:SI 2 "nonmemory_operand" " i,D,r"))) (match_operand:SI 2 "nonmemory_operand" " i,D,r"))
(set (reg CC_REG) (const_int 0)))
(compare (and:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=D,D,r")
(const_int 0)))] (and:SI (match_dup 1) (match_dup 2)))]
"reload_completed && mn10300_match_ccmode (insn, CCZNmode)" "reload_completed && mn10300_match_ccmode (insn, CCZNmode)"
"@ "@
and %2,%0 and %2,%0
...@@ -1282,12 +1282,12 @@ ...@@ -1282,12 +1282,12 @@
) )
(define_insn "*iorsi3_flags" (define_insn "*iorsi3_flags"
[(set (match_operand:SI 0 "register_operand" "=D,D,r") [(set (reg CC_REG)
(ior:SI (match_operand:SI 1 "register_operand" "%0,0,r") (compare (ior:SI (match_operand:SI 1 "register_operand" "%0,0,r")
(match_operand:SI 2 "nonmemory_operand" " i,D,r"))) (match_operand:SI 2 "nonmemory_operand" " i,D,r"))
(set (reg CC_REG) (const_int 0)))
(compare (ior:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=D,D,r")
(const_int 0)))] (ior:SI (match_dup 1) (match_dup 2)))]
"reload_completed && mn10300_match_ccmode (insn, CCZNmode)" "reload_completed && mn10300_match_ccmode (insn, CCZNmode)"
"@ "@
or %2,%0 or %2,%0
...@@ -1318,12 +1318,12 @@ ...@@ -1318,12 +1318,12 @@
) )
(define_insn "*xorsi3_flags" (define_insn "*xorsi3_flags"
[(set (match_operand:SI 0 "register_operand" "=D,D,r") [(set (reg CC_REG)
(xor:SI (match_operand:SI 1 "register_operand" "%0,0,r") (compare (xor:SI (match_operand:SI 1 "register_operand" "%0,0,r")
(match_operand:SI 2 "nonmemory_operand" " i,D,r"))) (match_operand:SI 2 "nonmemory_operand" " i,D,r"))
(set (reg CC_REG) (const_int 0)))
(compare (xor:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=D,D,r")
(const_int 0)))] (xor:SI (match_dup 1) (match_dup 2)))]
"reload_completed && mn10300_match_ccmode (insn, CCZNmode)" "reload_completed && mn10300_match_ccmode (insn, CCZNmode)"
"@ "@
xor %2,%0 xor %2,%0
...@@ -1346,11 +1346,11 @@ ...@@ -1346,11 +1346,11 @@
) )
(define_insn "*one_cmplsi2_flags" (define_insn "*one_cmplsi2_flags"
[(set (match_operand:SI 0 "register_operand" "=D") [(set (reg CC_REG)
(not:SI (match_operand:SI 1 "register_operand" " 0"))) (compare (not:SI (match_operand:SI 1 "register_operand" "0"))
(set (reg CC_REG) (const_int 0)))
(compare (not:SI (match_dup 1)) (set (match_operand:SI 0 "register_operand" "=D")
(const_int 0)))] (not:SI (match_dup 1)))]
"reload_completed && mn10300_match_ccmode (insn, CCZNmode)" "reload_completed && mn10300_match_ccmode (insn, CCZNmode)"
"not %0" "not %0"
) )
......
...@@ -3205,7 +3205,7 @@ rx_match_ccmode (rtx insn, machine_mode cc_mode) ...@@ -3205,7 +3205,7 @@ rx_match_ccmode (rtx insn, machine_mode cc_mode)
gcc_checking_assert (XVECLEN (PATTERN (insn), 0) == 2); gcc_checking_assert (XVECLEN (PATTERN (insn), 0) == 2);
op1 = XVECEXP (PATTERN (insn), 0, 1); op1 = XVECEXP (PATTERN (insn), 0, 0);
gcc_checking_assert (GET_CODE (SET_SRC (op1)) == COMPARE); gcc_checking_assert (GET_CODE (SET_SRC (op1)) == COMPARE);
flags = SET_DEST (op1); flags = SET_DEST (op1);
......
...@@ -932,10 +932,10 @@ single_set_and_flags (rtx_insn *insn) ...@@ -932,10 +932,10 @@ single_set_and_flags (rtx_insn *insn)
{ {
rtx pat = PATTERN (insn); rtx pat = PATTERN (insn);
if (XVECLEN (pat, 0) == 2 if (XVECLEN (pat, 0) == 2
&& GET_CODE (XVECEXP (pat, 0, 1)) == SET && GET_CODE (XVECEXP (pat, 0, 0)) == SET
&& REG_P (SET_DEST (XVECEXP (pat, 0, 1))) && REG_P (SET_DEST (XVECEXP (pat, 0, 0)))
&& REGNO (SET_DEST (XVECEXP (pat, 0, 1))) == FLAGS_REGNUM) && REGNO (SET_DEST (XVECEXP (pat, 0, 0))) == FLAGS_REGNUM)
return XVECEXP (pat, 0, 0); return XVECEXP (pat, 0, 1);
} }
return single_set (insn); return single_set (insn);
......
...@@ -251,9 +251,9 @@ ...@@ -251,9 +251,9 @@
[(set (match_operand 0 "") (match_operand 1 "")) [(set (match_operand 0 "") (match_operand 1 ""))
(clobber (reg:CC R_FLAGS))] (clobber (reg:CC R_FLAGS))]
"" ""
[(set (match_dup 0) (match_dup 1)) [(set (reg:CC R_FLAGS)
(set (reg:CC R_FLAGS) (compare:CC (match_dup 1) (const_int 0)))
(compare:CC (match_dup 1) (const_int 0)))]) (set (match_dup 0) (match_dup 1))])
(define_subst_attr "subst_logic" "flags_subst_logic" "_flags" "_set_flags") (define_subst_attr "subst_logic" "flags_subst_logic" "_flags" "_set_flags")
...@@ -261,9 +261,9 @@ ...@@ -261,9 +261,9 @@
[(set (match_operand 0 "") (match_operand 1 "")) [(set (match_operand 0 "") (match_operand 1 ""))
(clobber (reg:CC R_FLAGS))] (clobber (reg:CC R_FLAGS))]
"" ""
[(set (match_dup 0) (match_dup 1)) [(set (reg:CCNZ R_FLAGS)
(set (reg:CCNZ R_FLAGS) (compare:CCNZ (match_dup 1) (const_int 0)))
(compare:CCNZ (match_dup 1) (const_int 0)))]) (set (match_dup 0) (match_dup 1))])
(define_subst_attr "subst_arith" "flags_subst_arith" "_flags" "_set_flags") (define_subst_attr "subst_arith" "flags_subst_arith" "_flags" "_set_flags")
...@@ -794,23 +794,23 @@ ...@@ -794,23 +794,23 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*add<mode>3_insn_set_carry" (define_insn "*add<mode>3_insn_set_carry"
[(set (match_operand:QHI 0 "register_operand" "=r") [(set (reg:CCC R_FLAGS)
(plus:QHI (match_operand:QHI 1 "register_operand" "%r") (compare:CCC (plus:QHI (match_operand:QHI 1 "register_operand" "%r")
(match_operand:QHI 2 "register_operand" "r"))) (match_operand:QHI 2 "register_operand" "r"))
(set (reg:CCC R_FLAGS) (match_dup 1)))
(compare:CCC (plus:QHI (match_dup 1) (match_dup 2)) (set (match_operand:QHI 0 "register_operand" "=r")
(match_dup 1)))] (plus:QHI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"add<s> %0,%1,%2" "add<s> %0,%1,%2"
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*add<mode>3_insn_set_overflow" (define_insn "*add<mode>3_insn_set_overflow"
[(set (match_operand:QHI 0 "register_operand" "=r") [(set (reg:CCV R_FLAGS)
(plus:QHI (match_operand:QHI 1 "register_operand" "%r") (compare:CCV (plus:QHI (match_operand:QHI 1 "register_operand" "%r")
(match_operand:QHI 2 "register_operand" "r"))) (match_operand:QHI 2 "register_operand" "r"))
(set (reg:CCV R_FLAGS) (unspec:QHI [(match_dup 1) (match_dup 2)] UNSPEC_ADDV)))
(compare:CCV (plus:QHI (match_dup 1) (match_dup 2)) (set (match_operand:QHI 0 "register_operand" "=r")
(unspec:QHI [(match_dup 1) (match_dup 2)] UNSPEC_ADDV)))] (plus:QHI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"add<s> %0,%1,%2" "add<s> %0,%1,%2"
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
...@@ -858,12 +858,12 @@ ...@@ -858,12 +858,12 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "addsi3_insn_set_carry" (define_insn "addsi3_insn_set_carry"
[(set (match_operand:SI 0 "register_operand" "=r,r") [(set (reg:CCC R_FLAGS)
(plus:SI (match_operand:SI 1 "register_operand" "%r,0") (compare:CCC (plus:SI (match_operand:SI 1 "register_operand" "%r,0")
(match_operand:SI 2 "real_add_operand" " r,J"))) (match_operand:SI 2 "real_add_operand" " r,J"))
(set (reg:CCC R_FLAGS) (match_dup 1)))
(compare:CCC (plus:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=r,r")
(match_dup 1)))] (plus:SI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"@ "@
add.l %0,%1,%2 add.l %0,%1,%2
...@@ -871,12 +871,12 @@ ...@@ -871,12 +871,12 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*addsi3_insn_set_overflow" (define_insn "*addsi3_insn_set_overflow"
[(set (match_operand:SI 0 "register_operand" "=r,r") [(set (reg:CCV R_FLAGS)
(plus:SI (match_operand:SI 1 "register_operand" "%r,0") (compare:CCV (plus:SI (match_operand:SI 1 "register_operand" "%r,0")
(match_operand:SI 2 "real_add_operand" " r,J"))) (match_operand:SI 2 "real_add_operand" " r,J"))
(set (reg:CCV R_FLAGS) (unspec:SI [(match_dup 1) (match_dup 2)] UNSPEC_ADDV)))
(compare:CCV (plus:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=r,r")
(unspec:SI [(match_dup 1) (match_dup 2)] UNSPEC_ADDV)))] (plus:SI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"@ "@
add.l %0,%1,%2 add.l %0,%1,%2
...@@ -1009,22 +1009,22 @@ ...@@ -1009,22 +1009,22 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*sub<mode>3_insn_set_carry" (define_insn "*sub<mode>3_insn_set_carry"
[(set (match_operand:QHI 0 "register_operand" "=r") [(set (reg:CC R_FLAGS)
(minus:QHI (match_operand:QHI 1 "reg_or_0_operand" "rO") (compare:CC (match_operand:QHI 1 "reg_or_0_operand" "r0")
(match_operand:QHI 2 "register_operand" "r"))) (match_operand:QHI 2 "register_operand" "r")))
(set (reg:CC R_FLAGS) (set (match_operand:QHI 0 "register_operand" "=r")
(compare:CC (match_dup 1) (match_dup 2)))] (minus:QHI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"sub<s> %0,%r1,%2" "sub<s> %0,%r1,%2"
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*sub<mode>3_insn_set_overflow" (define_insn "*sub<mode>3_insn_set_overflow"
[(set (match_operand:QHI 0 "register_operand" "=r") [(set (reg:CCV R_FLAGS)
(minus:QHI (match_operand:QHI 1 "reg_or_0_operand" "rO") (compare:CCV (minus:QHI (match_operand:QHI 1 "reg_or_0_operand" "r0")
(match_operand:QHI 2 "register_operand" "r"))) (match_operand:QHI 2 "register_operand" "r"))
(set (reg:CCV R_FLAGS) (unspec:QHI [(match_dup 1) (match_dup 2)] UNSPEC_SUBV)))
(compare:CCV (minus:QHI (match_dup 1) (match_dup 2)) (set (match_operand:QHI 0 "register_operand" "=r")
(unspec:QHI [(match_dup 1) (match_dup 2)] UNSPEC_SUBV)))] (minus:QHI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"sub<s> %0,%r1,%2" "sub<s> %0,%r1,%2"
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
...@@ -1072,11 +1072,11 @@ ...@@ -1072,11 +1072,11 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "subsi3_insn_set_carry" (define_insn "subsi3_insn_set_carry"
[(set (match_operand:SI 0 "register_operand" "=r,r") [(set (reg:CC R_FLAGS)
(minus:SI (match_operand:SI 1 "register_operand" " r,0") (compare:CC (match_operand:SI 1 "register_operand" "r,0")
(match_operand:SI 2 "real_add_operand" " r,J"))) (match_operand:SI 2 "real_add_operand" "r,J")))
(set (reg:CC R_FLAGS) (set (match_operand:SI 0 "register_operand" "=r,r")
(compare:CC (match_dup 1) (match_dup 2)))] (minus:SI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"@ "@
sub.l %0,%r1,%2 sub.l %0,%r1,%2
...@@ -1084,12 +1084,12 @@ ...@@ -1084,12 +1084,12 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*subsi3_insn_set_overflow" (define_insn "*subsi3_insn_set_overflow"
[(set (match_operand:SI 0 "register_operand" "=r,r") [(set (reg:CCV R_FLAGS)
(minus:SI (match_operand:SI 1 "register_operand" " r,0") (compare:CCV (minus:SI (match_operand:SI 1 "register_operand" "r,0")
(match_operand:SI 2 "real_add_operand" " r,J"))) (match_operand:SI 2 "real_add_operand" "r,J"))
(set (reg:CCV R_FLAGS) (unspec:SI [(match_dup 1) (match_dup 2)] UNSPEC_SUBV)))
(compare:CCV (minus:SI (match_dup 1) (match_dup 2)) (set (match_operand:SI 0 "register_operand" "=r,r")
(unspec:SI [(match_dup 1) (match_dup 2)] UNSPEC_SUBV)))] (minus:SI (match_dup 1) (match_dup 2)))]
"reload_completed" "reload_completed"
"@ "@
sub.l %0,%1,%2 sub.l %0,%1,%2
...@@ -1209,20 +1209,21 @@ ...@@ -1209,20 +1209,21 @@
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "negsi2_insn_set_carry" (define_insn "negsi2_insn_set_carry"
[(set (match_operand:SI 0 "register_operand" "=r") [(set (reg:CCC R_FLAGS)
(neg:SI (match_operand:SI 1 "register_operand" "r"))) (compare:CCC (not:SI (match_operand:SI 1 "register_operand" "r"))
(set (reg:CCC R_FLAGS) (const_int -1)))
(compare:CCC (not:SI (match_dup 1)) (const_int -1)))] (set (match_operand:SI 0 "register_operand" "=r")
(neg:SI (match_dup 1)))]
"reload_completed" "reload_completed"
"sub.l %0,r0,%1" "sub.l %0,r0,%1"
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
(define_insn "*neg<mode>2_insn_set_overflow" (define_insn "*neg<mode>2_insn_set_overflow"
[(set (match_operand:I 0 "register_operand" "=r") [(set (reg:CCV R_FLAGS)
(neg:I (match_operand:I 1 "register_operand" "r"))) (compare:CCV (neg:I (match_operand:I 1 "register_operand" "r"))
(set (reg:CCV R_FLAGS) (unspec:I [(match_dup 1)] UNSPEC_NEGV)))
(compare:CCV (neg:I (match_dup 1)) (set (match_operand:I 0 "register_operand" "=r")
(unspec:I [(match_dup 1)] UNSPEC_NEGV)))] (neg:I (match_dup 1)))]
"reload_completed" "reload_completed"
"sub<s> %0,r0,%1" "sub<s> %0,r0,%1"
[(set_attr "type" "arith")]) [(set_attr "type" "arith")])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment