OSDN Git Service

Don't performance load/op/store transformation if op produces a floating point
authorEvan Cheng <evan.cheng@apple.com>
Tue, 29 Aug 2006 18:37:37 +0000 (18:37 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Tue, 29 Aug 2006 18:37:37 +0000 (18:37 +0000)
or vector result. X86 does not have load/mod/store variants of those
instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29957 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/X86ISelDAGToDAG.cpp

index 9697f25..6605473 100644 (file)
@@ -312,7 +312,9 @@ void X86DAGToDAGISel::InstructionSelectPreprocess(SelectionDAG &DAG) {
 
     SDOperand N1 = I->getOperand(1);
     SDOperand N2 = I->getOperand(2);
-    if (!N1.hasOneUse())
+    if (MVT::isFloatingPoint(N1.getValueType()) &&
+        MVT::isVector(N1.getValueType()) &&
+        !N1.hasOneUse())
       continue;
 
     bool RModW = false;