},
AddCC => {
- irn_flags => [ "rematerializable" ],
+ irn_flags => [ "rematerializable", "modifies_flags" ],
emit => '. addcc %S0, %R1I, %D0',
outs => [ "res", "flags" ],
constructors => \%binopcc_operand_constructors,
},
+AddCCZero => {
+ irn_flags => [ "rematerializable", "modifies_flags" ],
+ emit => '. addcc %S0, %R1I, %%g0',
+ mode => $mode_flags,
+ constructors => \%binopcczero_operand_constructors,
+},
+
AddX => {
# At the moment not rematerializable because of assert in beflags.c/
# (it claims that spiller can't rematerialize flag stuff correctly)
},
SubCC => {
- irn_flags => [ "rematerializable" ],
+ irn_flags => [ "rematerializable", "modifies_flags" ],
emit => '. subcc %S0, %R1I, %D0',
outs => [ "res", "flags" ],
constructors => \%binopcc_operand_constructors,
},
+SubCCZero => {
+ irn_flags => [ "rematerializable", "modifies_flags" ],
+ emit => '. subcc %S0, %R1I, %%g0',
+ mode => $mode_flags,
+ constructors => \%binopcczero_operand_constructors,
+},
+
SubX => {
# Not rematerializable (see AddX)
emit => '. subx %S0, %R1I, %D0',
constructors => \%binop_operand_constructors,
},
+MulCCZero => {
+ irn_flags => [ "rematerializable", "modifies_flags" ],
+ emit => '. smulcc %S0, %R1I, %%g0',
+ mode => $mode_flags,
+ constructors => \%binopcczero_operand_constructors,
+},
+
SMulh => {
irn_flags => [ "rematerializable" ],
outs => [ "low", "high" ],
new_bd_sparc_XNorCCZero_reg,
new_bd_sparc_XNorCCZero_imm,
MATCH_NONE);
+ } else if (is_Add(op1)) {
+ return gen_helper_binop(op1, MATCH_COMMUTATIVE,
+ new_bd_sparc_AddCCZero_reg,
+ new_bd_sparc_AddCCZero_imm);
+ } else if (is_Sub(op1)) {
+ return gen_helper_binop(op1, MATCH_NONE,
+ new_bd_sparc_SubCCZero_reg,
+ new_bd_sparc_SubCCZero_imm);
+ } else if (is_Mul(op1)) {
+ return gen_helper_binop(op1, MATCH_COMMUTATIVE,
+ new_bd_sparc_MulCCZero_reg,
+ new_bd_sparc_MulCCZero_imm);
}
}