[llvm-commits] [poolalloc] r56881 - in /poolalloc/trunk: include/poolalloc/PoolAllocate.h lib/PoolAllocate/PASimple.cpp lib/PoolAllocate/PoolAllocate.cpp lib/PoolAllocate/TransformFunctionBody.cpp

John Criswell criswell at uiuc.edu
Tue Sep 30 14:00:41 PDT 2008


Author: criswell
Date: Tue Sep 30 16:00:41 2008
New Revision: 56881

URL: http://llvm.org/viewvc/llvm-project?rev=56881&view=rev
Log:
Updated to new EquivClassGraph API; use hasDSGraph() instead of hasGraph() or
ContainsDSGraphFor().

Modified:
    poolalloc/trunk/include/poolalloc/PoolAllocate.h
    poolalloc/trunk/lib/PoolAllocate/PASimple.cpp
    poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp
    poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp

Modified: poolalloc/trunk/include/poolalloc/PoolAllocate.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/poolalloc/PoolAllocate.h?rev=56881&r1=56880&r2=56881&view=diff

==============================================================================
--- poolalloc/trunk/include/poolalloc/PoolAllocate.h (original)
+++ poolalloc/trunk/include/poolalloc/PoolAllocate.h Tue Sep 30 16:00:41 2008
@@ -120,7 +120,7 @@
   virtual const Type * getPoolType() {return 0;}
 
   virtual bool hasDSGraph (const Function & F) const {
-    return ECGraphs->hasGraph (F);
+    return ECGraphs->hasDSGraph (F);
   }
 
   virtual DSGraph & getDSGraph (const Function & F) const {

Modified: poolalloc/trunk/lib/PoolAllocate/PASimple.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/PASimple.cpp?rev=56881&r1=56880&r2=56881&view=diff

==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PASimple.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PASimple.cpp Tue Sep 30 16:00:41 2008
@@ -124,7 +124,7 @@
   CombinedDSGraph = new DSGraph (GlobalECs, TD, &(ECGraphs->getGlobalsGraph()));
   //CombinedDSGraph.cloneInto (getGlobalsGraph());
   for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I) {
-    if (ECGraphs->hasGraph (*I))
+    if (ECGraphs->hasDSGraph (*I))
       CombinedDSGraph->cloneInto (ECGraphs->getDSGraph(*I));
   }
   CombinedDSGraph->cloneInto (ECGraphs->getGlobalsGraph());

Modified: poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp?rev=56881&r1=56880&r2=56881&view=diff

==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp Tue Sep 30 16:00:41 2008
@@ -125,7 +125,7 @@
   // Loop over the functions in the original program finding the pool desc.
   // arguments necessary for each function that is indirectly callable.
   for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)
-    if (!I->isDeclaration() && ECGraphs->ContainsDSGraphFor(*I))
+    if (!I->isDeclaration() && ECGraphs->hasDSGraph(*I))
       FindFunctionPoolArgs(*I);
 
   std::map<Function*, Function*> FuncMap;
@@ -138,7 +138,7 @@
 {TIME_REGION(X, "MakeFunctionClone");
   for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)
     if (!I->isDeclaration() && !ClonedFunctions.count(I) &&
-        ECGraphs->ContainsDSGraphFor(*I))
+        ECGraphs->hasDSGraph(*I))
       if (Function *Clone = MakeFunctionClone(*I)) {
         FuncMap[I] = Clone;
         ClonedFunctions.insert(Clone);
@@ -150,7 +150,7 @@
 {TIME_REGION(X, "ProcessFunctionBody");
   for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)
     if (!I->isDeclaration() && !ClonedFunctions.count(I) &&
-        ECGraphs->ContainsDSGraphFor(*I)) {
+        ECGraphs->hasDSGraph(*I)) {
       std::map<Function*, Function*>::iterator FI = FuncMap.find(I);
       ProcessFunctionBody(*I, FI != FuncMap.end() ? *FI->second : *I);
     }

Modified: poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp?rev=56881&r1=56880&r2=56881&view=diff

==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp Tue Sep 30 16:00:41 2008
@@ -596,7 +596,7 @@
     NewCallee = CFI->Clone;
     ArgNodes = CFI->ArgNodes;
     
-    assert ((ECGraphs.hasGraph (*CF)) && "Function has no ECGraph!\n");
+    assert ((ECGraphs.hasDSGraph (*CF)) && "Function has no ECGraph!\n");
     CalleeGraph = &ECGraphs.getDSGraph(*CF);
   } else {
     DEBUG(std::cerr << "  Handling indirect call: " << *TheCall);





More information about the llvm-commits mailing list