summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorJames Y Knight <jyknight@google.com>2015-08-05 17:00:30 +0000
committerJames Y Knight <jyknight@google.com>2015-08-05 17:00:30 +0000
commitbce20afe0f563aa803bf1740985f1ef5d26d7a36 (patch)
treeb5ec5c5ed0fc554345c0404399473a362fb552f8 /llvm/lib
parent81167fb799a8dd8378c2824f6fb65264403976e7 (diff)
downloadbcm5719-llvm-bce20afe0f563aa803bf1740985f1ef5d26d7a36.tar.gz
bcm5719-llvm-bce20afe0f563aa803bf1740985f1ef5d26d7a36.zip
[Sparc] Fix disassembly of popc instruction.
And add tests. Patch by David Wiberg! llvm-svn: 244064
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/Sparc/SparcInstrInfo.td4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/Sparc/SparcInstrInfo.td b/llvm/lib/Target/Sparc/SparcInstrInfo.td
index 3b9e048ea8b..51b71f49144 100644
--- a/llvm/lib/Target/Sparc/SparcInstrInfo.td
+++ b/llvm/lib/Target/Sparc/SparcInstrInfo.td
@@ -1221,8 +1221,8 @@ let Predicates = [HasV9] in {
// the top 32-bits before using it. To do this clearing, we use a SRLri X,0.
let rs1 = 0 in
def POPCrr : F3_1<2, 0b101110,
- (outs IntRegs:$dst), (ins IntRegs:$src),
- "popc $src, $dst", []>, Requires<[HasV9]>;
+ (outs IntRegs:$rd), (ins IntRegs:$rs2),
+ "popc $rs2, $rd", []>, Requires<[HasV9]>;
def : Pat<(ctpop i32:$src),
(POPCrr (SRLri $src, 0))>;
OpenPOWER on IntegriCloud