Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Jastadd2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
JastAdd
Jastadd2
Commits
1d634044
Commit
1d634044
authored
4 years ago
by
René Schöne
Browse files
Options
Downloads
Patches
Plain Diff
Add two new events for tracing start and end of dependency notification.
parent
7bc880fb
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/template/incremental/ASTChange.tt
+14
-2
14 additions, 2 deletions
src/template/incremental/ASTChange.tt
src/template/trace/Tracer.tt
+16
-0
16 additions, 0 deletions
src/template/trace/Tracer.tt
with
30 additions
and
2 deletions
src/template/incremental/ASTChange.tt
+
14
−
2
View file @
1d634044
...
...
@@ -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
]]
This diff is collapsed.
Click to expand it.
src/template/trace/Tracer.tt
+
16
−
0
View file @
1d634044
...
...
@@ -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.
*/
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment