From: Anton Korobeynikov Date: Sun, 3 May 2009 13:15:03 +0000 (+0000) Subject: Implement bswap X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=49ebc2278472656e05541248eaedccb13e1b7d7d;p=oota-llvm.git Implement bswap git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70753 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/MSP430/MSP430InstrInfo.td b/lib/Target/MSP430/MSP430InstrInfo.td index 63576b0b212..df60209d3da 100644 --- a/lib/Target/MSP430/MSP430InstrInfo.td +++ b/lib/Target/MSP430/MSP430InstrInfo.td @@ -602,13 +602,12 @@ def SEXT16r : Pseudo<(outs GR16:$dst), (ins GR16:$src), [(set GR16:$dst, (sext_inreg GR16:$src, i8)), (implicit SRW)]>; -//def SEXT16r : Pseudo<(outs GR16:$dst), (ins GR16:$src), -// "sxt\t$dst", -// [(set GR16:$dst, (sext_inreg GR16:$src, i8)), -// (implicit SRW)]>; - } // Defs = [SRW] +def SWPB16r : Pseudo<(outs GR16:$dst), (ins GR16:$src), + "swpb\t$dst", + [(set GR16:$dst, (bswap GR16:$src))]>; + let isCommutable = 1 in { // X = OR Y, Z == X = OR Z, Y def OR8rr : Pseudo<(outs GR8:$dst), (ins GR8:$src1, GR8:$src2), "bis.b\t{$src2, $dst}",