[llvm] r309962 - Revert "[AArch64] Simplify AES*Tied pseudo expansion (NFC)."
Tim Northover via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 3 09:59:36 PDT 2017
Author: tnorthover
Date: Thu Aug 3 09:59:36 2017
New Revision: 309962
URL: http://llvm.org/viewvc/llvm-project?rev=309962&view=rev
Log:
Revert "[AArch64] Simplify AES*Tied pseudo expansion (NFC)."
This reverts commit r309821.
My suggestion was wrong because it left the MachineOperands tied which
confused the verifier. Since there's no easy way to untie operands, the
original BuildMI solution is probably best.
Modified:
llvm/trunk/lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp
Modified: llvm/trunk/lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp?rev=309962&r1=309961&r2=309962&view=diff
==============================================================================
--- llvm/trunk/lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp (original)
+++ llvm/trunk/lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp Thu Aug 3 09:59:36 2017
@@ -967,10 +967,17 @@ bool AArch64ExpandPseudo::expandMI(Machi
return expandCMP_SWAP_128(MBB, MBBI, NextMBBI);
case AArch64::AESMCrrTied:
- case AArch64::AESIMCrrTied:
- MI.setDesc(TII->get(Opcode == AArch64::AESMCrrTied ? AArch64::AESMCrr :
- AArch64::AESIMCrr));
+ case AArch64::AESIMCrrTied: {
+ MachineInstrBuilder MIB =
+ BuildMI(MBB, MBBI, MI.getDebugLoc(),
+ TII->get(Opcode == AArch64::AESMCrrTied ? AArch64::AESMCrr :
+ AArch64::AESIMCrr))
+ .add(MI.getOperand(0))
+ .add(MI.getOperand(1));
+ transferImpOps(MI, MIB, MIB);
+ MI.eraseFromParent();
return true;
+ }
}
return false;
}
More information about the llvm-commits
mailing list