[llvm-commits] CVS: llvm-poolalloc/lib/DSA/BottomUpClosure.cpp CallTargets.cpp DataStructure.cpp DataStructureAA.cpp DataStructureOpt.cpp DataStructureStats.cpp GraphChecker.cpp Local.cpp Printer.cpp Steensgaard.cpp TopDownClosure.cpp

Andrew Lenharth alenhar2 at cs.uiuc.edu
Tue Apr 17 16:41:30 PDT 2007



Changes in directory llvm-poolalloc/lib/DSA:

BottomUpClosure.cpp updated: 1.131 -> 1.132
CallTargets.cpp updated: 1.11 -> 1.12
DataStructure.cpp updated: 1.260 -> 1.261
DataStructureAA.cpp updated: 1.42 -> 1.43
DataStructureOpt.cpp updated: 1.18 -> 1.19
DataStructureStats.cpp updated: 1.27 -> 1.28
GraphChecker.cpp updated: 1.24 -> 1.25
Local.cpp updated: 1.169 -> 1.170
Printer.cpp updated: 1.93 -> 1.94
Steensgaard.cpp updated: 1.70 -> 1.71
TopDownClosure.cpp updated: 1.99 -> 1.100
---
Log message:

Normalize Flag names and functions, also add a couple informative ones

---
Diffs of the changes:  (+74 -78)

 BottomUpClosure.cpp    |    4 ++--
 CallTargets.cpp        |    4 ++--
 DataStructure.cpp      |   38 +++++++++++++++++---------------------
 DataStructureAA.cpp    |   12 ++++++------
 DataStructureOpt.cpp   |    6 +++---
 DataStructureStats.cpp |    2 +-
 GraphChecker.cpp       |   16 ++++++++--------
 Local.cpp              |   42 +++++++++++++++++++++---------------------
 Printer.cpp            |   16 ++++++++--------
 Steensgaard.cpp        |   10 +++++-----
 TopDownClosure.cpp     |    2 +-
 11 files changed, 74 insertions(+), 78 deletions(-)


Index: llvm-poolalloc/lib/DSA/BottomUpClosure.cpp
diff -u llvm-poolalloc/lib/DSA/BottomUpClosure.cpp:1.131 llvm-poolalloc/lib/DSA/BottomUpClosure.cpp:1.132
--- llvm-poolalloc/lib/DSA/BottomUpClosure.cpp:1.131	Wed Apr 11 12:37:43 2007
+++ llvm-poolalloc/lib/DSA/BottomUpClosure.cpp	Tue Apr 17 18:41:06 2007
@@ -133,7 +133,7 @@
   if (CS.isDirectCall()) {
     if (isResolvableFunc(CS.getCalleeFunc()))
       Callees.push_back(CS.getCalleeFunc());
-  } else if (!CS.getCalleeNode()->isIncomplete()) {
+  } else if (!CS.getCalleeNode()->isIncompleteNode()) {
     // Get all callees.
     unsigned OldSize = Callees.size();
     CS.getCalleeNode()->addFullFunctionList(Callees);
@@ -313,7 +313,7 @@
 
     // Free should take a single pointer argument, mark it as heap memory.
     DSNodeHandle N(new DSNode(0, DSG));
-    N.getNode()->setHeapNodeMarker();
+    N.getNode()->setHeapMarker();
     DSG->getNodeForValue(F->arg_begin()).mergeWith(N);
 
   } else {


Index: llvm-poolalloc/lib/DSA/CallTargets.cpp
diff -u llvm-poolalloc/lib/DSA/CallTargets.cpp:1.11 llvm-poolalloc/lib/DSA/CallTargets.cpp:1.12
--- llvm-poolalloc/lib/DSA/CallTargets.cpp:1.11	Fri Feb 23 16:49:32 2007
+++ llvm-poolalloc/lib/DSA/CallTargets.cpp	Tue Apr 17 18:41:06 2007
@@ -53,11 +53,11 @@
               DSNode* N = T->getDSGraph(*cs.getCaller())
                 .getNodeForValue(cs.getCalledValue()).getNode();
               N->addFullFunctionList(IndMap[cs]);
-              if (N->isComplete() && IndMap[cs].size()) {
+              if (N->isCompleteNode() && IndMap[cs].size()) {
                 CompleteSites.insert(cs);
                 ++CompleteInd;
               } 
-              if (N->isComplete() && !IndMap[cs].size()) {
+              if (N->isCompleteNode() && !IndMap[cs].size()) {
                 ++CompleteEmpty;
                 cerr << "Call site empty: '"
                      << cs.getInstruction()->getName() 


Index: llvm-poolalloc/lib/DSA/DataStructure.cpp
diff -u llvm-poolalloc/lib/DSA/DataStructure.cpp:1.260 llvm-poolalloc/lib/DSA/DataStructure.cpp:1.261
--- llvm-poolalloc/lib/DSA/DataStructure.cpp:1.260	Wed Apr 11 12:37:43 2007
+++ llvm-poolalloc/lib/DSA/DataStructure.cpp	Tue Apr 17 18:41:06 2007
@@ -182,7 +182,7 @@
 void DSNode::assertOK() const {
   assert((Ty != Type::VoidTy ||
           Ty == Type::VoidTy && (Size == 0 ||
-                                 (NodeType & DSNode::Array))) &&
+                                 (NodeType & DSNode::ArrayNode))) &&
          "Node not OK!");
 
   assert(ParentGraph && "Node has no parent?");
@@ -203,7 +203,7 @@
   assert((Offset < To->Size || (Offset == To->Size && Offset == 0)) &&
          "Forwarded offset is wrong!");
   ForwardNH.setTo(To, Offset);
-  NodeType = DEAD;
+  NodeType = DeadNode;
   Size = 0;
   Ty = Type::VoidTy;
 
@@ -252,7 +252,7 @@
   // If this node has a size that is <= 1, we don't need to create a forwarding
   // node.
   if (getSize() <= 1) {
-    NodeType |= DSNode::Array;
+    NodeType |= DSNode::ArrayNode;
     Ty = Type::VoidTy;
     Size = 1;
     assert(Links.size() <= 1 && "Size is 1, but has more links?");
@@ -262,7 +262,7 @@
     // some referrers may have an offset that is > 0.  By forcing them to
     // forward, the forwarder has the opportunity to correct the offset.
     DSNode *DestNode = new DSNode(0, ParentGraph);
-    DestNode->NodeType = NodeType|DSNode::Array;
+    DestNode->NodeType = NodeType|DSNode::ArrayNode;
     DestNode->Ty = Type::VoidTy;
     DestNode->Size = 1;
     DestNode->Globals.swap(Globals);
@@ -535,8 +535,8 @@
     }
 
     Ty = NewTy;
-    NodeType &= ~Array;
-    if (WillBeArray) NodeType |= Array;
+    NodeType &= ~ArrayNode;
+    if (WillBeArray) NodeType |= ArrayNode;
     Size = NewTySize;
 
     // Calculate the number of outgoing links from this node.
@@ -632,8 +632,8 @@
 
     const Type *OldTy = Ty;
     Ty = NewTy;
-    NodeType &= ~Array;
-    if (WillBeArray) NodeType |= Array;
+    NodeType &= ~ArrayNode;
+    if (WillBeArray) NodeType |= ArrayNode;
     Size = NewTySize;
 
     // Must grow links to be the appropriate size...
@@ -1510,9 +1510,9 @@
   if (GlobalValue *GV = dyn_cast<GlobalValue>(Ptr)) {
     N->addGlobal(GV);
   } else if (isa<MallocInst>(Ptr)) {
-   N->setHeapNodeMarker();
+   N->setHeapMarker();
   } else if (isa<AllocaInst>(Ptr)) {
-    N->setAllocaNodeMarker();
+    N->setAllocaMarker();
   } else {
     assert(0 && "Illegal memory object input!");
   }
@@ -1535,9 +1535,9 @@
 
   // Remove alloca or mod/ref bits as specified...
   unsigned BitsToClear = ((CloneFlags & StripAllocaBit)? DSNode::AllocaNode : 0)
-    | ((CloneFlags & StripModRefBits)? (DSNode::Modified | DSNode::Read) : 0)
-    | ((CloneFlags & StripIncompleteBit)? DSNode::Incomplete : 0);
-  BitsToClear |= DSNode::DEAD;  // Clear dead flag...
+    | ((CloneFlags & StripModRefBits)? (DSNode::ModifiedNode | DSNode::ReadNode) : 0)
+    | ((CloneFlags & StripIncompleteBit)? DSNode::IncompleteNode : 0);
+  BitsToClear |= DSNode::DeadNode;  // Clear dead flag...
 
   for (node_const_iterator I = G.node_begin(), E = G.node_end(); I != E; ++I) {
     assert(!I->isForwarding() &&
@@ -1545,10 +1545,6 @@
     DSNode *New = new DSNode(*I, this);
     New->maskNodeTypes(~BitsToClear);
     OldNodeMap[I] = New;
-#ifdef LLVA_KERNEL
-    if (G.getPoolForNode(&*I)) 
-      PoolDescriptors[New] = G.getPoolForNode(&*I);
-#endif    
   }
 
 #ifndef NDEBUG
@@ -1925,7 +1921,7 @@
 //
 static void markIncompleteNode(DSNode *N) {
   // Stop recursion if no node, or if node already marked...
-  if (N == 0 || N->isIncomplete()) return;
+  if (N == 0 || N->isIncompleteNode()) return;
 
   // Actually mark the node
   N->setIncompleteMarker();
@@ -1999,7 +1995,7 @@
   if (DSNode *N = Edge.getNode())  // Is there an edge?
     if (N->getNumReferrers() == 1)  // Does it point to a lonely node?
       // No interesting info?
-      if ((N->getNodeFlags() & ~DSNode::Incomplete) == 0 &&
+      if ((N->getNodeFlags() & ~DSNode::IncompleteNode) == 0 &&
           N->getType() == Type::VoidTy && !N->isNodeCompletelyFolded())
         Edge.setTo(0, 0);  // Kill the edge!
 }
@@ -2037,7 +2033,7 @@
 
       // If the Callee is a useless edge, this must be an unreachable call site,
       // eliminate it.
-      if (Callee->getNumReferrers() == 1 && Callee->isComplete() &&
+      if (Callee->getNumReferrers() == 1 && Callee->isCompleteNode() &&
           Callee->getGlobalsList().empty()) {  // No useful info?
         DOUT << "WARNING: Useless call site found.\n";
         Calls.erase(OldIt);
@@ -2213,7 +2209,7 @@
       continue;
     }
 
-    if (Node.isComplete() && !Node.isModified() && !Node.isRead()) {
+    if (Node.isCompleteNode() && !Node.isModifiedNode() && !Node.isReadNode()) {
       // This is a useless node if it has no mod/ref info (checked above),
       // outgoing edges (which it cannot, as it is not modified in this
       // context), and it has no incoming edges.  If it is a global node it may


Index: llvm-poolalloc/lib/DSA/DataStructureAA.cpp
diff -u llvm-poolalloc/lib/DSA/DataStructureAA.cpp:1.42 llvm-poolalloc/lib/DSA/DataStructureAA.cpp:1.43
--- llvm-poolalloc/lib/DSA/DataStructureAA.cpp:1.42	Fri Feb 23 16:49:32 2007
+++ llvm-poolalloc/lib/DSA/DataStructureAA.cpp	Tue Apr 17 18:41:06 2007
@@ -143,7 +143,7 @@
     return AliasAnalysis::alias(V1, V1Size, V2, V2Size);
 
   // We can only make a judgment if one of the nodes is complete.
-  if (N1->isComplete() || N2->isComplete()) {
+  if (N1->isCompleteNode() || N2->isCompleteNode()) {
     if (N1 != N2)
       return NoAlias;   // Completely different nodes.
 
@@ -197,9 +197,9 @@
     // track of aggregate mod/ref info.
     bool NeverReads = true, NeverWrites = true;
     for (; Range.first != Range.second; ++Range.first) {
-      if (Range.first->second->isModified())
+      if (Range.first->second->isModifiedNode())
         NeverWrites = false;
-      if (Range.first->second->isRead())
+      if (Range.first->second->isReadNode())
         NeverReads = false;
       if (NeverReads == false && NeverWrites == false)
         return AliasAnalysis::getModRefInfo(CS, P, Size);
@@ -240,7 +240,7 @@
 
     // If we found a node and it's complete, it cannot be passed out to the
     // called function.
-    if (NI->second.getNode()->isComplete())
+    if (NI->second.getNode()->isCompleteNode())
       return NoModRef;
     return AliasAnalysis::getModRefInfo(CS, P, Size);
   }
@@ -270,9 +270,9 @@
         // Otherwise, if the node is only M or R, return this.  This can be
         // useful for globals that should be marked const but are not.
         DSNode *N = NI->second.getNode();
-        if (!N->isModified())
+        if (!N->isModifiedNode())
           Result = (ModRefResult)(Result & ~Mod);
-        if (!N->isRead())
+        if (!N->isReadNode())
           Result = (ModRefResult)(Result & ~Ref);
       }
     }


Index: llvm-poolalloc/lib/DSA/DataStructureOpt.cpp
diff -u llvm-poolalloc/lib/DSA/DataStructureOpt.cpp:1.18 llvm-poolalloc/lib/DSA/DataStructureOpt.cpp:1.19
--- llvm-poolalloc/lib/DSA/DataStructureOpt.cpp:1.18	Fri Feb 23 16:49:32 2007
+++ llvm-poolalloc/lib/DSA/DataStructureOpt.cpp	Tue Apr 17 18:41:06 2007
@@ -76,11 +76,11 @@
           I->replaceAllUsesWith(Constant::getNullValue((Type*)I->getType()));
           ++NumGlobalsIsolated;
         }
-      } else if (GNode && GNode->isComplete()) {
+      } else if (GNode && GNode->isCompleteNode()) {
 
         // If the node has not been read or written, and it is not externally
         // visible, kill any references to it so it can be DCE'd.
-        if (!GNode->isModified() && !GNode->isRead() &&I->hasInternalLinkage()){
+        if (!GNode->isModifiedNode() && !GNode->isReadNode() &&I->hasInternalLinkage()){
           if (!I->use_empty()) {
             I->replaceAllUsesWith(Constant::getNullValue((Type*)I->getType()));
             ++NumGlobalsIsolated;
@@ -90,7 +90,7 @@
         // We expect that there will almost always be a node for this global.
         // If there is, and the node doesn't have the M bit set, we can set the
         // 'constant' bit on the global.
-        if (!GNode->isModified() && !I->isConstant()) {
+        if (!GNode->isModifiedNode() && !I->isConstant()) {
           I->setConstant(true);
           ++NumGlobalsConstanted;
           Changed = true;


Index: llvm-poolalloc/lib/DSA/DataStructureStats.cpp
diff -u llvm-poolalloc/lib/DSA/DataStructureStats.cpp:1.27 llvm-poolalloc/lib/DSA/DataStructureStats.cpp:1.28
--- llvm-poolalloc/lib/DSA/DataStructureStats.cpp:1.27	Wed Jan 10 13:59:52 2007
+++ llvm-poolalloc/lib/DSA/DataStructureStats.cpp	Tue Apr 17 18:41:06 2007
@@ -118,7 +118,7 @@
 
 bool DSGraphStats::isNodeForValueCollapsed(Value *V) {
   if (DSNode *N = getNodeForValue(V))
-    return N->isNodeCompletelyFolded() || N->isIncomplete();
+    return N->isNodeCompletelyFolded() || N->isIncompleteNode();
   return false;
 }
 


Index: llvm-poolalloc/lib/DSA/GraphChecker.cpp
diff -u llvm-poolalloc/lib/DSA/GraphChecker.cpp:1.24 llvm-poolalloc/lib/DSA/GraphChecker.cpp:1.25
--- llvm-poolalloc/lib/DSA/GraphChecker.cpp:1.24	Wed Dec 13 23:51:06 2006
+++ llvm-poolalloc/lib/DSA/GraphChecker.cpp	Tue Apr 17 18:41:06 2007
@@ -150,14 +150,14 @@
       unsigned Flags = 0;
       for (unsigned C = ColonPos+1; C != I->size(); ++C)
         switch ((*I)[C]) {
-        case 'S': Flags |= DSNode::AllocaNode;  break;
-        case 'H': Flags |= DSNode::HeapNode;    break;
-        case 'G': Flags |= DSNode::GlobalNode;  break;
-        case 'U': Flags |= DSNode::UnknownNode; break;
-        case 'I': Flags |= DSNode::Incomplete;  break;
-        case 'M': Flags |= DSNode::Modified;    break;
-        case 'R': Flags |= DSNode::Read;        break;
-        case 'A': Flags |= DSNode::Array;       break;
+        case 'S': Flags |= DSNode::AllocaNode;      break;
+        case 'H': Flags |= DSNode::HeapNode;        break;
+        case 'G': Flags |= DSNode::GlobalNode;      break;
+        case 'U': Flags |= DSNode::UnknownNode;     break;
+        case 'I': Flags |= DSNode::IncompleteNode;  break;
+        case 'M': Flags |= DSNode::ModifiedNode;    break;
+        case 'R': Flags |= DSNode::ReadNode;        break;
+        case 'A': Flags |= DSNode::ArrayNode;       break;
         default: cerr << "Invalid DSNode flag!\n"; abort();
         }
       CheckFlagsM[std::string(I->begin(), I->begin()+ColonPos)] = Flags;


Index: llvm-poolalloc/lib/DSA/Local.cpp
diff -u llvm-poolalloc/lib/DSA/Local.cpp:1.169 llvm-poolalloc/lib/DSA/Local.cpp:1.170
--- llvm-poolalloc/lib/DSA/Local.cpp:1.169	Wed Apr 11 12:37:43 2007
+++ llvm-poolalloc/lib/DSA/Local.cpp	Tue Apr 17 18:41:06 2007
@@ -101,14 +101,14 @@
     friend class InstVisitor<GraphBuilder>;
 
     void visitMallocInst(MallocInst &MI)
-    { setDestTo(MI, createNode()->setHeapNodeMarker()); }
+    { setDestTo(MI, createNode()->setHeapMarker()); }
 
     void visitAllocaInst(AllocaInst &AI)
-    { setDestTo(AI, createNode()->setAllocaNodeMarker()); }
+    { setDestTo(AI, createNode()->setAllocaMarker()); }
 
     void visitFreeInst(FreeInst &FI)
     { if (DSNode *N = getValueDest(*FI.getOperand(0)).getNode())
-        N->setHeapNodeMarker();
+        N->setHeapMarker();
     }
 
     //the simple ones
@@ -208,14 +208,14 @@
         if (isa<PointerType>(CE->getOperand(0)->getType()))
           NH = getValueDest(*CE->getOperand(0));
         else
-          NH = createNode()->setUnknownNodeMarker();
+          NH = createNode()->setUnknownMarker();
       } else if (CE->getOpcode() == Instruction::GetElementPtr) {
         visitGetElementPtrInst(*CE);
         assert(G.hasNodeForValue(CE) && "GEP didn't get processed right?");
         NH = G.getNodeForValue(CE);
       } else {
         // This returns a conservative unknown node for any unhandled ConstExpr
-        return NH = createNode()->setUnknownNodeMarker();
+        return NH = createNode()->setUnknownMarker();
       }
       if (NH.isNull()) {  // (getelementptr null, X) returns null
         G.eraseNodeForValue(V);
@@ -339,12 +339,12 @@
 }
 
 void GraphBuilder::visitIntToPtrInst(IntToPtrInst &I) {
-  setDestTo(I, createNode()->setUnknownNodeMarker()); //->setIntToPtrMarker()); 
+  setDestTo(I, createNode()->setUnknownMarker()->setIntToPtrMarker()); 
 }
 
 void GraphBuilder::visitPtrToIntInst(PtrToIntInst& I) {
-//   if (DSNode* N = getValueDest(*I.getOperand(0)).getNode())
-//     N->setPtrToIntMarker();
+  if (DSNode* N = getValueDest(*I.getOperand(0)).getNode())
+    N->setPtrToIntMarker();
 }
 
 
@@ -519,7 +519,7 @@
 bool GraphBuilder::visitIntrinsic(CallSite CS, Function *F) {
   switch (F->getIntrinsicID()) {
   case Intrinsic::vastart:
-    getValueDest(*CS.getInstruction()).getNode()->setAllocaNodeMarker();
+    getValueDest(*CS.getInstruction()).getNode()->setAllocaMarker();
     return true;
   case Intrinsic::vacopy:
     getValueDest(*CS.getInstruction()).
@@ -561,14 +561,14 @@
       || F->getName() == "posix_memalign"
       || F->getName() == "memalign" || F->getName() == "valloc") {
     setDestTo(*CS.getInstruction(),
-              createNode()->setHeapNodeMarker()->setModifiedMarker());
+              createNode()->setHeapMarker()->setModifiedMarker());
     return true;
   } else if (F->getName() == "realloc") {
     DSNodeHandle RetNH = getValueDest(*CS.getInstruction());
     if (CS.arg_begin() != CS.arg_end())
       RetNH.mergeWith(getValueDest(**CS.arg_begin()));
     if (DSNode *N = RetNH.getNode())
-      N->setHeapNodeMarker()->setModifiedMarker()->setReadMarker();
+      N->setHeapMarker()->setModifiedMarker()->setReadMarker();
     return true;
   } else if (F->getName() == "memmove") {
     // Merge the first & second arguments, and mark the memory read and
@@ -581,7 +581,7 @@
   } else if (F->getName() == "free") {
     // Mark that the node is written to...
     if (DSNode *N = getValueDest(**CS.arg_begin()).getNode())
-      N->setModifiedMarker()->setHeapNodeMarker();
+      N->setModifiedMarker()->setHeapMarker();
   } else if (F->getName() == "atoi" || F->getName() == "atof" ||
              F->getName() == "atol" || F->getName() == "atoll" ||
              F->getName() == "remove" || F->getName() == "unlink" ||
@@ -669,7 +669,7 @@
     // descriptor.  Also, merge the allocated type into the node.
     DSNodeHandle Result = getValueDest(*CS.getInstruction());
     if (DSNode *N = Result.getNode()) {
-      N->setModifiedMarker()->setUnknownNodeMarker();
+      N->setModifiedMarker()->setUnknownMarker();
       const Type *RetTy = F->getFunctionType()->getReturnType();
       if (const PointerType *PTy = dyn_cast<PointerType>(RetTy))
               N->mergeTypeInfo(PTy->getElementType(), Result.getOffset());
@@ -689,7 +689,7 @@
     // file descriptor.  It merges the FILE type into the descriptor.
     DSNodeHandle H = getValueDest(**CS.arg_begin());
     if (DSNode *N = H.getNode()) {
-      N->setReadMarker()->setUnknownNodeMarker();
+      N->setReadMarker()->setUnknownMarker();
       const Type *ArgTy = F->getFunctionType()->getParamType(0);
       if (const PointerType *PTy = dyn_cast<PointerType>(ArgTy))
         N->mergeTypeInfo(PTy->getElementType(), H.getOffset());
@@ -965,7 +965,7 @@
     DSNodeHandle RetNH = getValueDest(*CS.getInstruction());
     RetNH.mergeWith(getValueDest(**CS.arg_begin()));
     if (DSNode *N = RetNH.getNode())
-      N->setHeapNodeMarker()->setModifiedMarker()->setReadMarker();
+      N->setHeapMarker()->setModifiedMarker()->setReadMarker();
     //and read second pointer
     if (DSNode *N = getValueDest(**(CS.arg_begin() + 1)).getNode())
       N->setReadMarker();
@@ -976,7 +976,7 @@
     DSNodeHandle RetNH = getValueDest(*CS.getInstruction());
     RetNH.mergeWith(getValueDest(**CS.arg_begin()));
     if (DSNode *N = RetNH.getNode())
-      N->setHeapNodeMarker()->setModifiedMarker();
+      N->setHeapMarker()->setModifiedMarker();
     //and read second pointer
     if (DSNode *N = getValueDest(**(CS.arg_begin() + 1)).getNode())
             N->setReadMarker();
@@ -989,7 +989,7 @@
 
     // Create a new DSNode for this memory allocation
     DSNode *N = createNode();
-    N->setHeapNodeMarker();
+    N->setHeapMarker();
     setDestTo(*CS.getInstruction(), N);
 
     // Get the pool handle
@@ -1051,7 +1051,7 @@
 
     // Create a DSNode for the memory allocated by this function call
     DSNode *N = createNode();
-    N->setHeapNodeMarker();
+    N->setHeapMarker();
     setDestTo(*CS.getInstruction(), N);
 
     // Get the pool handle, if possible
@@ -1146,7 +1146,7 @@
         // allocation functions
         if (AllocList.end() != std::find(AllocList.begin(), AllocList.end(), F->getName())) {
           setDestTo(*CS.getInstruction(),
-                    createNode()->setHeapNodeMarker()->setModifiedMarker());
+                    createNode()->setHeapMarker()->setModifiedMarker());
           return;
         }
 
@@ -1156,7 +1156,7 @@
                                         F->getName())) {
           // Mark that the node is written to...
           if (DSNode *N = getValueDest(*(CS.getArgument(0))).getNode())
-            N->setModifiedMarker()->setHeapNodeMarker();
+            N->setModifiedMarker()->setHeapMarker();
           return;
         }
 
@@ -1222,7 +1222,7 @@
       CurNode.mergeWith(getValueDest(**I));
 
   if (DSNode *N = CurNode.getNode())
-    N->setUnknownNodeMarker();
+    N->setUnknownMarker();
 }
 
 


Index: llvm-poolalloc/lib/DSA/Printer.cpp
diff -u llvm-poolalloc/lib/DSA/Printer.cpp:1.93 llvm-poolalloc/lib/DSA/Printer.cpp:1.94
--- llvm-poolalloc/lib/DSA/Printer.cpp:1.93	Wed Jan 10 12:10:32 2007
+++ llvm-poolalloc/lib/DSA/Printer.cpp	Tue Apr 17 18:41:06 2007
@@ -64,15 +64,15 @@
   }
   if (unsigned NodeType = N->getNodeFlags()) {
     OS << ": ";
-    if (NodeType & DSNode::AllocaNode ) OS << "S";
-    if (NodeType & DSNode::HeapNode   ) OS << "H";
-    if (NodeType & DSNode::GlobalNode ) OS << "G";
-    if (NodeType & DSNode::UnknownNode) OS << "U";
-    if (NodeType & DSNode::Incomplete ) OS << "I";
-    if (NodeType & DSNode::Modified   ) OS << "M";
-    if (NodeType & DSNode::Read       ) OS << "R";
+    if (NodeType & DSNode::AllocaNode     ) OS << "S";
+    if (NodeType & DSNode::HeapNode       ) OS << "H";
+    if (NodeType & DSNode::GlobalNode     ) OS << "G";
+    if (NodeType & DSNode::UnknownNode    ) OS << "U";
+    if (NodeType & DSNode::IncompleteNode ) OS << "I";
+    if (NodeType & DSNode::ModifiedNode   ) OS << "M";
+    if (NodeType & DSNode::ReadNode       ) OS << "R";
 #ifndef NDEBUG
-    if (NodeType & DSNode::DEAD       ) OS << "<dead>";
+    if (NodeType & DSNode::DeadNode       ) OS << "<dead>";
 #endif
     OS << "\n";
   }


Index: llvm-poolalloc/lib/DSA/Steensgaard.cpp
diff -u llvm-poolalloc/lib/DSA/Steensgaard.cpp:1.70 llvm-poolalloc/lib/DSA/Steensgaard.cpp:1.71
--- llvm-poolalloc/lib/DSA/Steensgaard.cpp:1.70	Wed Apr 11 12:37:43 2007
+++ llvm-poolalloc/lib/DSA/Steensgaard.cpp	Tue Apr 17 18:41:06 2007
@@ -212,8 +212,8 @@
     // this.  If one is complete and the other isn't, then they are obviously
     // different nodes.  If they are both complete, we can't say anything
     // useful.
-    if (I->second.getNode()->isComplete() ||
-        J->second.getNode()->isComplete()) {
+    if (I->second.getNode()->isCompleteNode() ||
+        J->second.getNode()->isCompleteNode()) {
       // If the two pointers point to different data structure graph nodes, they
       // cannot alias!
       if (V1H.getNode() != V2H.getNode())
@@ -251,7 +251,7 @@
 
   if (I != GSM.end() && !I->second.isNull()) {
     DSNode *N = I->second.getNode();
-    if (N->isComplete()) {
+    if (N->isCompleteNode()) {
       // If this is a direct call to an external function, and if the pointer
       // points to a complete node, the external function cannot modify or read
       // the value (we know it's not passed out of the program!).
@@ -261,9 +261,9 @@
 
       // Otherwise, if the node is complete, but it is only M or R, return this.
       // This can be useful for globals that should be marked const but are not.
-      if (!N->isModified())
+      if (!N->isModifiedNode())
         Result = (ModRefResult)(Result & ~Mod);
-      if (!N->isRead())
+      if (!N->isReadNode())
         Result = (ModRefResult)(Result & ~Ref);
     }
   }


Index: llvm-poolalloc/lib/DSA/TopDownClosure.cpp
diff -u llvm-poolalloc/lib/DSA/TopDownClosure.cpp:1.99 llvm-poolalloc/lib/DSA/TopDownClosure.cpp:1.100
--- llvm-poolalloc/lib/DSA/TopDownClosure.cpp:1.99	Wed Apr 11 12:37:43 2007
+++ llvm-poolalloc/lib/DSA/TopDownClosure.cpp	Tue Apr 17 18:41:06 2007
@@ -73,7 +73,7 @@
   for (DSScalarMap::global_iterator I=GGSM.global_begin(), E=GGSM.global_end();
        I != E; ++I) {
     DSNode *N = GGSM.find(*I)->second.getNode();
-    if (N->isIncomplete())
+    if (N->isIncompleteNode())
       markReachableFunctionsExternallyAccessible(N, Visited);
   }
 






More information about the llvm-commits mailing list