Analyzing gc logs

前端 未结 1 1812
甜味超标
甜味超标 2020-11-28 12:28

I am using -XX:+PrintGCApplicationStoppedTime and -XX:+PrintGCApplicationConcurrentTime options to turn on gc logging.

But found that only

相关标签:
1条回答
  • 2020-11-28 13:08

    Unfortunately PrintGCApplicationStoppedTime is misleading name for this JVM option.

    In fact it prints the time spent inside safepoints. Safepoint pauses occur not only due to Garbage Collection, but for many other reasons:

    • Deoptimization
    • Biased lock revocation
    • Thread dump
    • Heap inspection
    • Class redifinition
    • etc. (see the list)

    Safepoints may happen periodically even without a requested VM operation in order to deflate idle monitors, perform certain JIT cleanup and so on. See -XX:GuaranteedSafepointInterval VM option (1000 milliseconds by default).

    Use -XX:+PrintSafepointStatistics -XX:PrintSafepointStatisticsCount=1 to dump more information about safepoints.

    0 讨论(0)
提交回复
热议问题