;; leave out the mode in operand 4 and use one pattern, but reload can
;; change the mode underneath our feet and then gets confused trying
;; to reload the value.
-(define_mode_iterator CCEITHER [CC CCUNS])
-(define_mode_attr un [(CC "") (CCUNS "un")])
-(define_insn "isel_<un>signed_<GPR:mode>"
+(define_mode_iterator CCANY [CC CCUNS])
+(define_insn "isel_<CCANY:mode>_<GPR:mode>"
[(set (match_operand:GPR 0 "gpc_reg_operand" "=r,r")
(if_then_else:GPR
(match_operator 1 "scc_comparison_operator"
- [(match_operand:CCEITHER 4 "cc_reg_operand" "y,y")
+ [(match_operand:CCANY 4 "cc_reg_operand" "y,y")
(const_int 0)])
(match_operand:GPR 2 "reg_or_zero_operand" "O,b")
(match_operand:GPR 3 "gpc_reg_operand" "r,r")))]
;; isel can handle reversed comparisons so long as the operands are
;; registers.
-(define_insn "*isel_reversed_<un>signed_<GPR:mode>"
+(define_insn "*isel_reversed_<CCANY:mode>_<GPR:mode>"
[(set (match_operand:GPR 0 "gpc_reg_operand" "=r,r")
(if_then_else:GPR
(match_operator 1 "scc_rev_comparison_operator"
- [(match_operand:CCEITHER 4 "cc_reg_operand" "y,y")
+ [(match_operand:CCANY 4 "cc_reg_operand" "y,y")
(const_int 0)])
(match_operand:GPR 2 "gpc_reg_operand" "r,r")
(match_operand:GPR 3 "reg_or_zero_operand" "O,b")))]
[(set_attr "type" "isel")])
; Set Boolean Condition (Reverse)
-(define_insn "setbc_<un>signed_<GPR:mode>"
+(define_insn "setbc_<CCANY:mode>_<GPR:mode>"
[(set (match_operand:GPR 0 "gpc_reg_operand" "=r")
(match_operator:GPR 1 "scc_comparison_operator"
- [(match_operand:CCEITHER 2 "cc_reg_operand" "y")
+ [(match_operand:CCANY 2 "cc_reg_operand" "y")
(const_int 0)]))]
"TARGET_POWER10"
"setbc %0,%j1"
[(set_attr "type" "isel")])
-(define_insn "*setbcr_<un>signed_<GPR:mode>"
+(define_insn "*setbcr_<CCANY:mode>_<GPR:mode>"
[(set (match_operand:GPR 0 "gpc_reg_operand" "=r")
(match_operator:GPR 1 "scc_rev_comparison_operator"
- [(match_operand:CCEITHER 2 "cc_reg_operand" "y")
+ [(match_operand:CCANY 2 "cc_reg_operand" "y")
(const_int 0)]))]
"TARGET_POWER10"
"setbcr %0,%j1"
[(set_attr "type" "isel")])
; Set Negative Boolean Condition (Reverse)
-(define_insn "*setnbc_<un>signed_<GPR:mode>"
+(define_insn "*setnbc_<CCANY:mode>_<GPR:mode>"
[(set (match_operand:GPR 0 "gpc_reg_operand" "=r")
(neg:GPR (match_operator:GPR 1 "scc_comparison_operator"
- [(match_operand:CCEITHER 2 "cc_reg_operand" "y")
+ [(match_operand:CCANY 2 "cc_reg_operand" "y")
(const_int 0)])))]
"TARGET_POWER10"
"setnbc %0,%j1"
[(set_attr "type" "isel")])
-(define_insn "*setnbcr_<un>signed_<GPR:mode>"
+(define_insn "*setnbcr_<CCANY:mode>_<GPR:mode>"
[(set (match_operand:GPR 0 "gpc_reg_operand" "=r")
(neg:GPR (match_operator:GPR 1 "scc_rev_comparison_operator"
- [(match_operand:CCEITHER 2 "cc_reg_operand" "y")
+ [(match_operand:CCANY 2 "cc_reg_operand" "y")
(const_int 0)])))]
"TARGET_POWER10"
"setnbcr %0,%j1"
rtx compare = gen_rtx_COMPARE (CCmode, operands[1], operands[2]);
emit_insn (gen_rtx_SET (cc, compare));
rtx eq = gen_rtx_fmt_ee (EQ, <MODE>mode, cc, const0_rtx);
- emit_insn (gen_setbc_signed_<mode> (operands[0], eq, cc));
+ emit_insn (gen_setbc_cc_<mode> (operands[0], eq, cc));
DONE;
}
rtx compare = gen_rtx_COMPARE (CCmode, operands[1], operands[2]);
emit_insn (gen_rtx_SET (cc, compare));
rtx ne = gen_rtx_fmt_ee (NE, <MODE>mode, cc, const0_rtx);
- emit_insn (gen_setbc_signed_<mode> (operands[0], ne, cc));
+ emit_insn (gen_setbc_cc_<mode> (operands[0], ne, cc));
DONE;
}