[llvm-commits] [polly] r131353 - /polly/trunk/lib/CodeGeneration.cpp

Tobias Grosser grosser at fim.uni-passau.de
Sat May 14 12:01:56 PDT 2011


Author: grosser
Date: Sat May 14 14:01:55 2011
New Revision: 131353

URL: http://llvm.org/viewvc/llvm-project?rev=131353&view=rev
Log:
CodeGeneration: Remove -polly-codegen-only

If we only want to optimize a single function, we should extract this function
into a separate .ll file. This simplifies the code.

Modified:
    polly/trunk/lib/CodeGeneration.cpp

Modified: polly/trunk/lib/CodeGeneration.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGeneration.cpp?rev=131353&r1=131352&r2=131353&view=diff
==============================================================================
--- polly/trunk/lib/CodeGeneration.cpp (original)
+++ polly/trunk/lib/CodeGeneration.cpp Sat May 14 14:01:55 2011
@@ -78,12 +78,6 @@
        cl::value_desc("OpenMP code generation enabled if true"),
        cl::init(false));
 
-static cl::opt<std::string>
-CodegenOnly("polly-codegen-only",
-            cl::desc("Codegen only this function"), cl::Hidden,
-            cl::value_desc("The function name to codegen"),
-            cl::ValueRequired, cl::init(""));
-
 typedef DenseMap<const Value*, Value*> ValueMapT;
 typedef DenseMap<const char*, Value*> CharMapT;
 typedef std::vector<ValueMapT> VectorValueMapT;
@@ -1354,6 +1348,7 @@
       // Update RegionInfo.
       splitBlock = region->getEntry();
       region->replaceEntry(newBlock);
+      RI->setRegionFor(newBlock, region);
     } else {
       RI->setRegionFor(newBlock, region->getParent());
       splitBlock = newBlock;
@@ -1428,13 +1423,6 @@
 
     parallelLoops.clear();
 
-    Function *F = region->getEntry()->getParent();
-    if (CodegenOnly != "" && CodegenOnly != F->getNameStr()) {
-      errs() << "Codegenerating only function '" << CodegenOnly
-        << "' skipping '" << F->getNameStr() << "' \n";
-      return false;
-    }
-
     assert(region->isSimple() && "Only simple regions are supported");
 
     // In the CFG and we generate next to original code of the Scop the





More information about the llvm-commits mailing list