RFR: 8330625: Compilation memory statistic: prevent tearing of the final report [v2]

Thomas Stuefe stuefe at openjdk.org
Tue Apr 23 05:26:53 UTC 2024


> Somewhat trivial change to reduce the chance of tearing the final compilation cost history report. See JBS for details.
> 
> ---
> 
> The patch:
> - upon end of a compilation, we print the the offending log line and account the cost in the compilation cost history table. For the latter we lock over NMTCompilationCostHistory_lock. The patch swaps these two actions such that we print after pulling the lock. That greatly reduces, albeit not completely removes, the chance of printing log lines into the final report. (I did not want to widen the scope of that lock to include the printout)
> - also moves the locking of NMTCompilationCostHistory_lock  up to the start of the reporting function to include printing the report header into the locking

Thomas Stuefe has updated the pull request incrementally with one additional commit since the last revision:

  print newlines around report

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/18866/files
  - new: https://git.openjdk.org/jdk/pull/18866/files/92049dda..58bf813f

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=18866&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=18866&range=00-01

  Stats: 2 lines in 1 file changed: 2 ins; 0 del; 0 mod
  Patch: https://git.openjdk.org/jdk/pull/18866.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/18866/head:pull/18866

PR: https://git.openjdk.org/jdk/pull/18866


More information about the hotspot-compiler-dev mailing list