From 33c110e602bbdfee23cfb58fddef246a262647ab Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Sat, 7 May 2011 04:37:27 +0000 Subject: [PATCH] Fix the non-MC encoding of pkhbt and pkhtb. Patch by Stephen Hines. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131045 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/ARM/ARMCodeEmitter.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/Target/ARM/ARMCodeEmitter.cpp b/lib/Target/ARM/ARMCodeEmitter.cpp index fa7371626f2..d0c0e952512 100644 --- a/lib/Target/ARM/ARMCodeEmitter.cpp +++ b/lib/Target/ARM/ARMCodeEmitter.cpp @@ -1372,6 +1372,12 @@ void ARMCodeEmitter::emitMiscArithInstruction(const MachineInstr &MI) { // Set the conditional execution predicate Binary |= II->getPredicate(&MI) << ARMII::CondShift; + // PKH instructions are finished at this point + if (TID.Opcode == ARM::PKHBT || TID.Opcode == ARM::PKHTB) { + emitWordLE(Binary); + return; + } + unsigned OpIdx = 0; // Encode Rd -- 2.34.1