JDK-8255231 : Avoid upcalls when initializing the statSampler
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2020-10-22
  • Updated: 2024-12-09
  • Resolved: 2020-10-27
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 16
16 b22Fixed
Related Reports
Relates :  
Description
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.
Comments
Changeset: f7c59c66 Author: Claes Redestad <redestad@openjdk.org> Date: 2020-10-27 10:31:21 +0000 URL: https://git.openjdk.java.net/jdk/commit/f7c59c66
27-10-2020