[llvm-commits] [llvm] r82462 - /llvm/trunk/lib/Transforms/Scalar/CodeGenLICM.cpp

Dan Gohman gohman at apple.com
Mon Sep 21 10:53:35 PDT 2009


Author: djg
Date: Mon Sep 21 12:53:35 2009
New Revision: 82462

URL: http://llvm.org/viewvc/llvm-project?rev=82462&view=rev
Log:
Remove the special-case for constants in PHI nodes; it's not really
helpful, and it didn't correctly handle the case of constants input
to PHIs for backedges.

Modified:
    llvm/trunk/lib/Transforms/Scalar/CodeGenLICM.cpp

Modified: llvm/trunk/lib/Transforms/Scalar/CodeGenLICM.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/CodeGenLICM.cpp?rev=82462&r1=82461&r2=82462&view=diff

==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/CodeGenLICM.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/CodeGenLICM.cpp Mon Sep 21 12:53:35 2009
@@ -60,9 +60,6 @@
     for (BasicBlock::iterator BBI = BB->begin(), BBE = BB->end();
          BBI != BBE; ++BBI) {
       Instruction *I = BBI;
-      // Don't bother hoisting constants out of loop-header phi nodes.
-      if (BB == L->getHeader() && isa<PHINode>(I))
-        continue;
       // TODO: For now, skip all intrinsic instructions, because some of them
       // can require their operands to be constants, and we don't want to
       // break that.





More information about the llvm-commits mailing list