@@ -133,6 +133,7 @@ def MOV_indirect : Type3Inst<(outs GPR:$Ra), (ins MEMroffset:$Rb), 0b0011101, 1,
133
133
def ADD : Type3Inst<(outs GPR:$Ra), (ins GPR:$Rai, GPR:$Rb), 0b0011010, 0, "add", "$Ra, $Rb", "$Ra = $Rai">;
134
134
def SUB : Type3Inst<(outs GPR:$Ra), (ins GPR:$Rai, GPR:$Rb), 0b0011101, 0, "sub", "$Ra, $Rb", "$Ra = $Rai">;
135
135
def CMP : Type2Inst<(outs FR:$f), (ins GPR:$Ra, GPR:$Rb), 0b0000010, 0, "cmp", "$Ra, $Rb", "">;
136
+ def AND : Type2Inst<(outs GPR:$Ra), (ins GPR:$Rai, GPR:$Rb), 0b0000011, 0, "and", "$Ra, $Rb", "$Ra = $Rai">;
136
137
def OR : Type3Inst<(outs GPR:$Ra), (ins GPR:$Rai, GPR:$Rb), 0b0100000, 0, "or", "$Ra, $Rb", "$Ra = $Rai">;
137
138
def STR : Type3Inst<(outs), (ins MEMroffset:$Ra, GPR:$Rb), 0b0100001, 0, "str", "$Ra, $Rb", "">;
138
139
@@ -166,3 +167,4 @@ def : Pat<(add GPR:$Ra, GPR:$Rb), (ADD GPR:$Ra, GPR:$Rb)>;
166
167
def : Pat<(sub GPR:$Ra, GPR:$Rb), (SUB GPR:$Ra, GPR:$Rb)>;
167
168
def : Pat<(store GPR:$Rb, GPR:$Ra), (STR GPR:$Ra, (i16 0), GPR:$Rb)>;
168
169
def : Pat<(or GPR:$Ra, GPR:$Rb), (OR GPR:$Ra, GPR:$Rb)>;
170
+ def : Pat<(and GPR:$Ra, GPR:$Rb), (AND GPR:$Ra, GPR:$Rb)>;
0 commit comments