[llvm-commits] [llvm] r131156 - /llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp

Eli Friedman eli.friedman at gmail.com
Tue May 10 14:50:58 PDT 2011


Author: efriedma
Date: Tue May 10 16:50:58 2011
New Revision: 131156

URL: http://llvm.org/viewvc/llvm-project?rev=131156&view=rev
Log:
Disable my little CopyToReg argument hack with fast-isel.  rdar://problem/9413587 .


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

Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp?rev=131156&r1=131155&r2=131156&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp Tue May 10 16:50:58 2011
@@ -6440,10 +6440,11 @@
 
     // If this argument is live outside of the entry block, insert a copy from
     // wherever we got it to the vreg that other BB's will reference it as.
-    if (Res.getOpcode() == ISD::CopyFromReg) {
+    if (!EnableFastISel && Res.getOpcode() == ISD::CopyFromReg) {
       // If we can, though, try to skip creating an unnecessary vreg.
       // FIXME: This isn't very clean... it would be nice to make this more
-      // general.
+      // general.  It's also subtly incompatible with the hacks FastISel
+      // uses with vregs.
       unsigned Reg = cast<RegisterSDNode>(Res.getOperand(1))->getReg();
       if (TargetRegisterInfo::isVirtualRegister(Reg)) {
         FuncInfo->ValueMap[I] = Reg;





More information about the llvm-commits mailing list