Add the "isCompare" attribute to the defm instead of each individual instr.
llvm-svn: 111481
This commit is contained in:
parent
fa9fd03e2d
commit
768d3b510c
|
@ -523,7 +523,7 @@ multiclass T2I_sh_ir<bits<2> opcod, string opc, PatFrag opnode> {
|
||||||
/// T2I_cmp_irs - Defines a set of (op r, {so_imm|r|so_reg}) cmp / test
|
/// T2I_cmp_irs - Defines a set of (op r, {so_imm|r|so_reg}) cmp / test
|
||||||
/// patterns. Similar to T2I_bin_irs except the instruction does not produce
|
/// patterns. Similar to T2I_bin_irs except the instruction does not produce
|
||||||
/// a explicit result, only implicitly set CPSR.
|
/// a explicit result, only implicitly set CPSR.
|
||||||
let Defs = [CPSR] in {
|
let isCompare = 1, Defs = [CPSR] in {
|
||||||
multiclass T2I_cmp_irs<bits<4> opcod, string opc, PatFrag opnode> {
|
multiclass T2I_cmp_irs<bits<4> opcod, string opc, PatFrag opnode> {
|
||||||
// shifted imm
|
// shifted imm
|
||||||
def ri : T2I<(outs), (ins GPR:$lhs, t2_so_imm:$rhs), IIC_iCMPi,
|
def ri : T2I<(outs), (ins GPR:$lhs, t2_so_imm:$rhs), IIC_iCMPi,
|
||||||
|
@ -2136,12 +2136,10 @@ def : T2Pat<(or (and rGPR:$src1, 0xFFFF0000),
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
// Comparison Instructions...
|
// Comparison Instructions...
|
||||||
//
|
//
|
||||||
let isCompare = 1 in {
|
|
||||||
defm t2CMP : T2I_cmp_irs<0b1101, "cmp",
|
defm t2CMP : T2I_cmp_irs<0b1101, "cmp",
|
||||||
BinOpFrag<(ARMcmp node:$LHS, node:$RHS)>>;
|
BinOpFrag<(ARMcmp node:$LHS, node:$RHS)>>;
|
||||||
defm t2CMPz : T2I_cmp_irs<0b1101, "cmp",
|
defm t2CMPz : T2I_cmp_irs<0b1101, "cmp",
|
||||||
BinOpFrag<(ARMcmpZ node:$LHS, node:$RHS)>>;
|
BinOpFrag<(ARMcmpZ node:$LHS, node:$RHS)>>;
|
||||||
}
|
|
||||||
|
|
||||||
//FIXME: Disable CMN, as CCodes are backwards from compare expectations
|
//FIXME: Disable CMN, as CCodes are backwards from compare expectations
|
||||||
// Compare-to-zero still works out, just not the relationals
|
// Compare-to-zero still works out, just not the relationals
|
||||||
|
|
Loading…
Reference in New Issue