On Mon, 26 Oct 2020 12:49:43 GMT, Claes Redestad <redes...@openjdk.org> wrote:
>> Current implementation of the statSampler does upcalls to System.getProperty >> to collect values for a number of properties that are all provided by the VM >> itself. And since the sampling starts before any user code run then no >> property can have changed. >> >> I suggest refactoring the code so that no upcalls are made normally - while >> asserting this invariant holds using assert-only upcalls. >> >> This is a small startup optimization - reducing the startup sequence by >> approx. 300k instructions and 70k branches in my linux-x64 setup. > > Claes Redestad has updated the pull request with a new target base due to a > merge or a rebase. The incremental webrev excludes the unrelated changes > brought in by the merge/rebase. The pull request contains 21 additional > commits since the last revision: > > - Address review comments from David Holmes > - Merge branch 'master' into com_ns > - Refactor to remove stable_java_property_counters and clarify comments > - Merge branch 'master' into com_ns > - Revert unrelated changes to perfData > - Merge branch 'master' into com_ns > - Improve comments > - typo > - Missing definition > - Extract the shorthand java.version from VersionProps and use it in > StatSampler > - ... and 11 more: > https://git.openjdk.java.net/jdk/compare/145a3876...8572159f Thanks for making the suggested changes. I think we need a further RFE to add some error checking for the sizes of the various property strings in relation to the fixed size arrays that have been allocated to them. Thanks, David ------------- Marked as reviewed by dholmes (Reviewer). PR: https://git.openjdk.java.net/jdk/pull/802