mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-18 11:24:01 +00:00
Rename NewNode flag to HeapNode
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4515 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -63,7 +63,7 @@ public:
|
|||||||
enum NodeTy {
|
enum NodeTy {
|
||||||
ShadowNode = 0, // Nothing is known about this node...
|
ShadowNode = 0, // Nothing is known about this node...
|
||||||
AllocaNode = 1 << 0, // This node was allocated with alloca
|
AllocaNode = 1 << 0, // This node was allocated with alloca
|
||||||
NewNode = 1 << 1, // This node was allocated with malloc
|
HeapNode = 1 << 1, // This node was allocated with malloc
|
||||||
GlobalNode = 1 << 2, // This node was allocated by a global var decl
|
GlobalNode = 1 << 2, // This node was allocated by a global var decl
|
||||||
UnknownNode = 1 << 3, // This node points to unknown allocated memory
|
UnknownNode = 1 << 3, // This node points to unknown allocated memory
|
||||||
Incomplete = 1 << 4, // This node may not be complete
|
Incomplete = 1 << 4, // This node may not be complete
|
||||||
|
@ -63,7 +63,7 @@ public:
|
|||||||
enum NodeTy {
|
enum NodeTy {
|
||||||
ShadowNode = 0, // Nothing is known about this node...
|
ShadowNode = 0, // Nothing is known about this node...
|
||||||
AllocaNode = 1 << 0, // This node was allocated with alloca
|
AllocaNode = 1 << 0, // This node was allocated with alloca
|
||||||
NewNode = 1 << 1, // This node was allocated with malloc
|
HeapNode = 1 << 1, // This node was allocated with malloc
|
||||||
GlobalNode = 1 << 2, // This node was allocated by a global var decl
|
GlobalNode = 1 << 2, // This node was allocated by a global var decl
|
||||||
UnknownNode = 1 << 3, // This node points to unknown allocated memory
|
UnknownNode = 1 << 3, // This node points to unknown allocated memory
|
||||||
Incomplete = 1 << 4, // This node may not be complete
|
Incomplete = 1 << 4, // This node may not be complete
|
||||||
|
@ -1003,10 +1003,11 @@ void GlobalDSGraph::removeReference(const DSGraph* referrer) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Bits used in the next function
|
|
||||||
static const char ExternalTypeBits = DSNode::GlobalNode | DSNode::NewNode;
|
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
|
// Bits used in the next function
|
||||||
|
static const char ExternalTypeBits = DSNode::GlobalNode | DSNode::HeapNode;
|
||||||
|
|
||||||
|
|
||||||
// GlobalDSGraph::cloneNodeInto - Clone a global node and all its externally
|
// GlobalDSGraph::cloneNodeInto - Clone a global node and all its externally
|
||||||
// visible target links (and recursively their such links) into this graph.
|
// visible target links (and recursively their such links) into this graph.
|
||||||
// NodeCache maps the node being cloned to its clone in the Globals graph,
|
// NodeCache maps the node being cloned to its clone in the Globals graph,
|
||||||
|
@ -84,7 +84,7 @@ namespace {
|
|||||||
private:
|
private:
|
||||||
// Visitor functions, used to handle each instruction type we encounter...
|
// Visitor functions, used to handle each instruction type we encounter...
|
||||||
friend class InstVisitor<GraphBuilder>;
|
friend class InstVisitor<GraphBuilder>;
|
||||||
void visitMallocInst(MallocInst &MI) { handleAlloc(MI, DSNode::NewNode); }
|
void visitMallocInst(MallocInst &MI) { handleAlloc(MI, DSNode::HeapNode); }
|
||||||
void visitAllocaInst(AllocaInst &AI) { handleAlloc(AI, DSNode::AllocaNode);}
|
void visitAllocaInst(AllocaInst &AI) { handleAlloc(AI, DSNode::AllocaNode);}
|
||||||
void handleAlloc(AllocationInst &AI, DSNode::NodeTy NT);
|
void handleAlloc(AllocationInst &AI, DSNode::NodeTy NT);
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ static string getCaption(const DSNode *N, const DSGraph *G) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (N->NodeType & DSNode::AllocaNode ) OS << "S";
|
if (N->NodeType & DSNode::AllocaNode ) OS << "S";
|
||||||
if (N->NodeType & DSNode::NewNode ) OS << "H";
|
if (N->NodeType & DSNode::HeapNode ) OS << "H";
|
||||||
if (N->NodeType & DSNode::GlobalNode ) OS << "G";
|
if (N->NodeType & DSNode::GlobalNode ) OS << "G";
|
||||||
if (N->NodeType & DSNode::UnknownNode) OS << "U";
|
if (N->NodeType & DSNode::UnknownNode) OS << "U";
|
||||||
if (N->NodeType & DSNode::Incomplete ) OS << "I";
|
if (N->NodeType & DSNode::Incomplete ) OS << "I";
|
||||||
|
Reference in New Issue
Block a user