[llvm-commits] [poolalloc] r50183 - in /poolalloc/trunk/lib/PoolAllocate: PASimple.cpp PoolAllocate.cpp

John Criswell criswell at uiuc.edu
Wed Apr 23 14:16:02 PDT 2008


Author: criswell
Date: Wed Apr 23 16:16:02 2008
New Revision: 50183

URL: http://llvm.org/viewvc/llvm-project?rev=50183&view=rev
Log:
Qualify make_pair() with the namespace.

Modified:
    poolalloc/trunk/lib/PoolAllocate/PASimple.cpp
    poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp

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

==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PASimple.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PASimple.cpp Wed Apr 23 16:16:02 2008
@@ -121,7 +121,7 @@
   // Create a silly Function Info structure for this function.
   //
   FuncInfo FInfo(F);
-  FunctionInfo.insert (make_pair(&F, FInfo));
+  FunctionInfo.insert (std::make_pair(&F, FInfo));
 
   //
   // Get the DSGraph for this function.
@@ -133,7 +133,7 @@
       if (MallocInst * MI = dyn_cast<MallocInst>(ii)) {
         // Associate the global pool decriptor with the DSNode
         DSNode * Node = ECG.getNodeForValue(MI).getNode();
-        FInfo.PoolDescriptors.insert(make_pair(Node,TheGlobalPool));
+        FInfo.PoolDescriptors.insert(std::make_pair(Node,TheGlobalPool));
 
         // Mark the malloc as an instruction to delete
         toDelete.push_back(ii);
@@ -161,7 +161,7 @@
       } else if (AllocaInst * AI = dyn_cast<AllocaInst>(ii)) {
 #if 0
         DSNode * Node = ECG.getNodeForValue(AI).getNode();
-        FInfo.PoolDescriptors.insert(make_pair(Node,TheGlobalPool));
+        FInfo.PoolDescriptors.insert(std::make_pair(Node,TheGlobalPool));
         toDelete.push_back(ii);
         //Fixme: fixup size
         Value* args[] = {TheGlobalPool, ii->getOperand(0)};
@@ -179,7 +179,7 @@
         if (CF && (CF->isDeclaration()) && (CF->getName() == "realloc")) {
           // Associate the global pool decriptor with the DSNode
           DSNode * Node = ECG.getNodeForValue(CI).getNode();
-          FInfo.PoolDescriptors.insert(make_pair(Node,TheGlobalPool));
+          FInfo.PoolDescriptors.insert(std::make_pair(Node,TheGlobalPool));
 
           // Mark the realloc as an instruction to delete
           toDelete.push_back(ii);
@@ -220,7 +220,7 @@
         } else if (CF && (CF->isDeclaration()) && (CF->getName() == "calloc")) {
           // Associate the global pool decriptor with the DSNode
           DSNode * Node = ECG.getNodeForValue(CI).getNode();
-          FInfo.PoolDescriptors.insert(make_pair(Node,TheGlobalPool));
+          FInfo.PoolDescriptors.insert(std::make_pair(Node,TheGlobalPool));
 
           // Mark the realloc as an instruction to delete
           toDelete.push_back(ii);
@@ -262,7 +262,7 @@
         } else if (CF && (CF->isDeclaration()) && (CF->getName() == "strdup")) {
           // Associate the global pool decriptor with the DSNode
           DSNode * Node = ECG.getNodeForValue(CI).getNode();
-          FInfo.PoolDescriptors.insert(make_pair(Node,TheGlobalPool));
+          FInfo.PoolDescriptors.insert(std::make_pair(Node,TheGlobalPool));
 
           // Mark the realloc as an instruction to delete
           toDelete.push_back(ii);

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

==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp Wed Apr 23 16:16:02 2008
@@ -40,9 +40,6 @@
 
 using namespace llvm;
 using namespace PA;
-#ifdef SAFECODE
-using namespace CUA;
-#endif
 
 char PoolAllocate::ID = 0;
 char PoolAllocatePassAllPools::ID = 0;
@@ -111,11 +108,6 @@
 
 bool PoolAllocate::runOnModule(Module &M) {
   if (M.begin() == M.end()) return false;
-#ifdef SAFECODE  
-#if 0
-  CUAPass = &getAnalysis<ConvertUnsafeAllocas>();
-#endif
-#endif  
   CurModule = &M;
   ECGraphs = &getAnalysis<EquivClassGraphs>();   // folded inlined CBU graphs
   if (UseTDResolve)





More information about the llvm-commits mailing list