[llvm-commits] CVS: llvm/lib/Target/X86/X86InstrInfo.cpp
Evan Cheng
evan.cheng at apple.com
Tue May 30 15:13:48 PDT 2006
Changes in directory llvm/lib/Target/X86:
X86InstrInfo.cpp updated: 1.55 -> 1.56
---
Log message:
Somehow I lost a condition when I was shuffling some code around. Anyway,
only transform a shufps to pshufd when the first two operands are the same.
---
Diffs of the changes: (+1 -1)
X86InstrInfo.cpp | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
Index: llvm/lib/Target/X86/X86InstrInfo.cpp
diff -u llvm/lib/Target/X86/X86InstrInfo.cpp:1.55 llvm/lib/Target/X86/X86InstrInfo.cpp:1.56
--- llvm/lib/Target/X86/X86InstrInfo.cpp:1.55 Tue May 30 16:45:53 2006
+++ llvm/lib/Target/X86/X86InstrInfo.cpp Tue May 30 17:13:36 2006
@@ -125,11 +125,11 @@
case X86::SHUFPSrri: {
assert(MI->getNumOperands() == 4 && "Unknown shufps instruction!");
const X86Subtarget *Subtarget = &TM.getSubtarget<X86Subtarget>();
- if (!Subtarget->hasSSE2()) return 0;
unsigned A = MI->getOperand(0).getReg();
unsigned B = MI->getOperand(1).getReg();
unsigned C = MI->getOperand(2).getReg();
unsigned M = MI->getOperand(3).getImmedValue();
+ if (!Subtarget->hasSSE2() || B != C) return 0;
return BuildMI(X86::PSHUFDri, 2, A).addReg(B).addImm(M);
}
}
More information about the llvm-commits
mailing list