-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add -Ydebug-tree-with-id n
#6363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
test performance please |
performance test scheduled: 1 job(s) in queue, 1 running. |
This postion allow descovering the place creation of a tree given its unique id. Adding is as a setting to simplify debuging on a released version of dotty.
5c34915
to
5bb1ee3
Compare
Performance test finished successfully: Visit http://dotty-bench.epfl.ch/6363/ to see the changes. Benchmarks is based on merging with master (2a033aa) |
val stack = Thread.currentThread().getStackTrace().map("> " + _) | ||
System.err.println(stack.mkString(s"> Debug tree (id=${Positioned.debugId}) creation \n> $this\n", "\n", "\n")) | ||
} | ||
printTrace() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is the logic abstracted into a method instead of inlining it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
uniqueId_=
is probably a hot path as each tree creation will have a call to it. I put the code contained in this debug branch to make the bytecode of uniqueId_=
smaller and probably simple to optimize from the JVM perspective.
test performance please |
performance test scheduled: 1 job(s) in queue, 1 running. |
Performance test finished successfully: Visit http://dotty-bench.epfl.ch/6363/ to see the changes. Benchmarks is based on merging with master (2b95f1d) |
This postion allow descovering the place creation of a tree given its unique id.
Adding is as a setting to simplify debuging on a released version of dotty.