diff options
| author | Dylan McKay <me@dylanmckay.io> | 2018-09-01 12:22:54 +0000 |
|---|---|---|
| committer | Dylan McKay <me@dylanmckay.io> | 2018-09-01 12:22:54 +0000 |
| commit | 97daa142f441b806cd1a0aaaee0d404ae54298c3 (patch) | |
| tree | 05fdfc80fc1cc1232c9bd48ab57316e0e8ddefa3 /llvm/lib | |
| parent | d11802438779edc773802b40dcfb3963eeca9f6e (diff) | |
| download | bcm5719-llvm-97daa142f441b806cd1a0aaaee0d404ae54298c3.tar.gz bcm5719-llvm-97daa142f441b806cd1a0aaaee0d404ae54298c3.zip | |
[AVR] Redefine the 'SBR' instruction as an alias
This fixes a TableGen warning about duplicate bit patterns.
SBR
===
This is an alias of 'ORI Rd, K'.
llvm-svn: 341277
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/AVR/AVRInstrInfo.td | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/llvm/lib/Target/AVR/AVRInstrInfo.td b/llvm/lib/Target/AVR/AVRInstrInfo.td index 62f06f2bf77..7fdb0e01574 100644 --- a/llvm/lib/Target/AVR/AVRInstrInfo.td +++ b/llvm/lib/Target/AVR/AVRInstrInfo.td @@ -732,6 +732,14 @@ Defs = [SREG] in // This operation is identical to a `Rd AND Rd`. def : InstAlias<"tst\t$rd", (ANDRdRr GPR8:$rd, GPR8:$rd)>; +// SBR Rd, K +// +// Mnemonic alias to 'ORI Rd, K'. Same bit pattern, same operands, +// same everything. +def : InstAlias<"sbr\t$rd, $k", + (ORIRdK LD8:$rd, imm_ldi8:$k), + /* Disable display, so we don't override ORI */ 0>; + //===----------------------------------------------------------------------===// // Jump instructions //===----------------------------------------------------------------------===// @@ -1730,15 +1738,6 @@ def BLD : FRdB<0b00, let Constraints = "$src = $rd", Defs = [SREG] in { - // SBR Rd, K - // Alias for ORI Rd, K - def SBRRdK : FRdK<0b0110, - (outs LD8:$rd), - (ins LD8:$src, imm_ldi8:$k), - "sbr\t$rd, $k", - [(set i8:$rd, (or i8:$src, imm:$k)), - (implicit SREG)]>; - // CBR Rd, K // Alias for `ANDI Rd, COM(K)` where COM(K) is the complement of K. // FIXME: This uses the 'complement' encoder. We need it to also use the |

