[llvm-commits] [llvm] r69008 - /llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp

Dale Johannesen dalej at apple.com
Mon Apr 13 17:56:56 PDT 2009


Author: johannes
Date: Mon Apr 13 19:56:56 2009
New Revision: 69008

URL: http://llvm.org/viewvc/llvm-project?rev=69008&view=rev
Log:
Do not force asm's to be chained if they don't touch
memory and aren't volatile.  This was interfering with
good scheduling.


Modified:
    llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp

Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp?rev=69008&r1=69007&r2=69008&view=diff

==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp Mon Apr 13 19:56:56 2009
@@ -5439,6 +5439,9 @@
     }
 
     setValue(CS.getInstruction(), Val);
+    // Don't need to use this as a chain in this case.
+    if (!IA->hasSideEffects() && !hasMemory && IndirectStoresToEmit.empty())
+      return;
   }
 
   std::vector<std::pair<SDValue, Value*> > StoresToEmit;





More information about the llvm-commits mailing list