Skip to content
Snippets Groups Projects
Commit 1d634044 authored by René Schöne's avatar René Schöne
Browse files

Add two new events for tracing start and end of dependency notification.

parent 7bc880fb
Branches
No related tags found
No related merge requests found
......@@ -63,6 +63,10 @@ $endif
ASTNode.incHookSetChild1 = [[
$if(IncrementalEnabled)
$if (TraceFlush)
Object flushIncToken = new Object();
state().trace().flushIncStart(this, "setChild", flushIncToken);
$endif
$if(IncrementalLevelParam)
if (state().disableDeps == 0 && !state().IN_ATTR_STORE_EVAL) {
......@@ -162,7 +166,9 @@ $endif
ASTNode.incHookSetChild5 = [[
$if(IncrementalEnabled)
$if (TraceFlush)
state().trace().flushIncEnd(this, "setChild", flushIncToken);
$endif
$endif
]]
......@@ -320,6 +326,10 @@ $endif
TokenComponent.incHookSetToken = [[
$if(IncrementalEnabled)
$if (TraceFlush)
Object flushIncToken = new Object();
state().trace().flushIncStart(this, "set$(Id)", flushIncToken);
$endif
$if(IncrementalLevelParam)
if (state().disableDeps == 0 && !state().IN_ATTR_STORE_EVAL) {
......@@ -390,6 +400,8 @@ if (state().disableDeps == 0 && !(state().IN_COMPUTATION > 0)) {
$endif
}
$if (TraceFlush)
state().trace().flushIncEnd(this, "set$(Id)", flushIncToken);
$endif
$endif
]]
......@@ -79,7 +79,9 @@ public static class Trace {
FLUSH_ATTR,
FLUSH_REWRITE,
FLUSH_REWRITE_INIT,
INC_FLUSH_START,
INC_FLUSH_ATTR,
INC_FLUSH_END,
// Flag: --tracing=coll
CONTRIBUTION_CHECK_BEGIN,
......@@ -341,6 +343,20 @@ public static class Trace {
receiver.accept($StateClass.Trace.Event.INC_FLUSH_ATTR, node, attr, params, value);
}
/**
* Trace that flushing done by incremental evaluation begun.
*/
public void flushIncStart($ASTNode node, String child, Object value) {
receiver.accept($StateClass.Trace.Event.INC_FLUSH_START, node, child, "", value);
}
/**
* Trace that flushing done by incremental evaluation ended.
*/
public void flushIncEnd($ASTNode node, String child, Object value) {
receiver.accept($StateClass.Trace.Event.INC_FLUSH_END, node, child, "", value);
}
/**
* Trace that a contribution check to a collection attribute begun.
*/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment