graal
graal copied to clipboard
Extend PrintAnalysisCallTree option
Current -H:+PrintAnalysisCallTree option prints call trees for all entries. However, the resulting file is too large to look for the method that user is interested in.
This PR extends the option to -H:PrintAnalysisCallTree=<comma-separated method list>. Only the specified entry methods' call tree will be printed out. And -H:PrintAnalysisCallTree= prints call tree for all entry methods, just like previous -H:+PrintAnalysisCallTree does.
The method name is the qualified name including parameter types, such as sun.nio.fs.UnixNativeDispatcher.<clinit>().
Hi @mcraj017, could you please assign this to someone for a review?
@zakkak thanks for the PR, I have assigned reviwers for this
@zakkak thanks for the PR, I have assigned reviwers for this
Well, the thanks for the PR go to @ziyilin. I didn't put any effort in this, I would just like to see it merged :) Thanks for pushing it forward.
@christianwimmer @vjovanov are there any updates on this?
Please document the new option format in
/docs/reference-manual/native-image/Reports.md. Is this supposed to work only for entry points, or any method can be selected?
Updated the reference file. It should report for any method selected.@cstancu please have a review. Thanks.
Hi @ziyilin, it looks like now that https://github.com/oracle/graal/pull/3128 got merged there are some conflicts in this PR, could you please have a look?
Hi @ziyilin, it looks like now that #3128 got merged there are some conflicts in this PR, could you please have a look?
@zakkak I've fixed the conflicts
Please consider my comment https://github.com/oracle/graal/issues/3843#issuecomment-932188028 before integrating this. I'd rather PrintAnalysisCallTree be set to either text or csv, and then have a complementary option for the filter itself.
Hello @cstancu, are there any updates on this?
This PR fell between cracks. If it's still relevant for you I have a few suggestions:
- instead of using a custom filter format I would use the same method filter format as
jdk.graal.MethodFilter, we used that recently also forAbortOnMethodReachablefor example. - instead of using having
-H:PrintAnalysisCallTreeFilter=set-H:+PrintAnalysisCallTreeI would just makeAnalysisCallTreeMethodFilteras a separate option, that's by default empty.