Commit 044a53b8 authored by Daniel Gröber (dxld)'s avatar Daniel Gröber (dxld) Committed by Marge Bot
Browse files

rts: TraverseHeap: Rename traversePushClosure to traversePushRoot

parent a04179e7
...@@ -349,9 +349,9 @@ retainRoot(void *user, StgClosure **tl) ...@@ -349,9 +349,9 @@ retainRoot(void *user, StgClosure **tl)
c = UNTAG_CLOSURE(*tl); c = UNTAG_CLOSURE(*tl);
traverseMaybeInitClosureData(c); traverseMaybeInitClosureData(c);
if (c != &stg_END_TSO_QUEUE_closure && isRetainer(c)) { if (c != &stg_END_TSO_QUEUE_closure && isRetainer(c)) {
traversePushClosure(ts, c, c, (stackData)getRetainerFrom(c)); traversePushRoot(ts, c, c, (stackData)getRetainerFrom(c));
} else { } else {
traversePushClosure(ts, c, c, (stackData)CCS_SYSTEM); traversePushRoot(ts, c, c, (stackData)CCS_SYSTEM);
} }
// NOT TRUE: ASSERT(isMember(getRetainerFrom(*tl), retainerSetOf(*tl))); // NOT TRUE: ASSERT(isMember(getRetainerFrom(*tl), retainerSetOf(*tl)));
......
...@@ -345,7 +345,7 @@ pushStackElement(traverseState *ts, const stackElement se) ...@@ -345,7 +345,7 @@ pushStackElement(traverseState *ts, const stackElement se)
* c - closure * c - closure
* data - data associated with closure. * data - data associated with closure.
*/ */
inline void STATIC_INLINE void
traversePushClosure(traverseState *ts, StgClosure *c, StgClosure *cp, stackData data) { traversePushClosure(traverseState *ts, StgClosure *c, StgClosure *cp, stackData data) {
stackElement se; stackElement se;
...@@ -357,6 +357,12 @@ traversePushClosure(traverseState *ts, StgClosure *c, StgClosure *cp, stackData ...@@ -357,6 +357,12 @@ traversePushClosure(traverseState *ts, StgClosure *c, StgClosure *cp, stackData
pushStackElement(ts, se); pushStackElement(ts, se);
}; };
void
traversePushRoot(traverseState *ts, StgClosure *c, StgClosure *cp, stackData data)
{
traversePushClosure(ts, c, cp, data);
};
/** /**
* traversePushChildren() extracts the first child of 'c' in 'first_child' and * traversePushChildren() extracts the first child of 'c' in 'first_child' and
* conceptually pushes all remaining children of 'c' onto the traversal stack * conceptually pushes all remaining children of 'c' onto the traversal stack
......
...@@ -106,7 +106,7 @@ typedef bool (*visitClosure_cb) ( ...@@ -106,7 +106,7 @@ typedef bool (*visitClosure_cb) (
stackData *child_data); stackData *child_data);
void traverseWorkStack(traverseState *ts, visitClosure_cb visit_cb); void traverseWorkStack(traverseState *ts, visitClosure_cb visit_cb);
void traversePushClosure(traverseState *ts, StgClosure *c, StgClosure *cp, stackData data); void traversePushRoot(traverseState *ts, StgClosure *c, StgClosure *cp, stackData data);
bool traverseMaybeInitClosureData(StgClosure *c); bool traverseMaybeInitClosureData(StgClosure *c);
void initializeTraverseStack(traverseState *ts); void initializeTraverseStack(traverseState *ts);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment