RFR: 8273112: -Xloggc:<filename> should override -verbose:gc [v4]

Xiaowei Lu github.com+39413832+weixlu at openjdk.java.net
Fri Sep 3 02:48:59 UTC 2021


> According to java 16 specifications for java command (https://docs.oracle.com/en/java/javase/16/docs/specs/man/java.html), the command line option -Xloggc should override -verbose:gc if both options are given with the same java command. However, gc information still outputs to console even if gc log file is specified.
> 
> $java -Xloggc:gc.log -verbose:gc -version
> [0.000s][warning][gc] -Xloggc is deprecated. Will use -Xlog:gc:gc.log instead.
> [0.003s][info ][gc] Using G1
> $cat gc.log
> [0.003s][info][gc] Using G1
> 
> As a result, we propose to put off the log configuration of -verbose:gc option until we are confident that there isn’t -Xloggc option.

Xiaowei Lu has updated the pull request incrementally with one additional commit since the last revision:

  fix initialization of _legacyGCLogging

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/5295/files
  - new: https://git.openjdk.java.net/jdk/pull/5295/files/f355e598..5f69d62d

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=5295&range=03
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=5295&range=02-03

  Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
  Patch: https://git.openjdk.java.net/jdk/pull/5295.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/5295/head:pull/5295

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


More information about the hotspot-runtime-dev mailing list