RFR: 8282024: add EscapeAnalysis statistics under PrintOptoStatistics [v8]

Xin Liu xliu at openjdk.java.net
Thu May 5 19:13:22 UTC 2022


On Wed, 4 May 2022 01:36:13 GMT, aamarsh <duke at openjdk.java.net> wrote:

>> Escape Analysis and Scalar Replacement statistics were added when the -XX:+PrintOptoStatistics flag is set. All code is placed in `#ifndef Product` block, so this code is only run when creating a debug build. Using renaissance benchmark I ran a few tests to confirm that numbers were printing correctly. Below is an example run:
>> 
>> 
>> No escape = 372, Arg escape = 74, Global escape = 1855 (EA executed in   10.49 seconds)
>> Objects scalar replaced = 240, Monitor objects removed = 44, GC barriers removed = 37, Memory barriers removed = 284
>
> aamarsh has refreshed the contents of this pull request, and previous commits have been removed. The incremental views will show differences compared to the previous content of the PR. The pull request contains one new commit since the last revision:
> 
>   adding escape analysis and scalar replacement statistics

LTGM. I am not a reviewer.  We need other reviewers to approve it.

src/hotspot/share/opto/escape.cpp line 3794:

> 3792:         _compile->_local_arg_escape_ctr++;
> 3793:       }
> 3794:       else if (ptn->escape_state() == PointsToNode::GlobalEscape) {

"else if" style is not consistent with others.

-------------

Marked as reviewed by xliu (Committer).

PR: https://git.openjdk.java.net/jdk/pull/8019


More information about the hotspot-compiler-dev mailing list