RFR: 8291753: Add JFR event for GC CPU Time [v5]

Sangheon Kim sangheki at openjdk.org
Thu Sep 8 00:07:05 UTC 2022


On Wed, 7 Sep 2022 16:11:50 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:

>> Sangheon Kim has updated the pull request incrementally with two additional commits since the last revision:
>> 
>>  - Merge remote-tracking branch 'origin/8291753-cpu-time' into 8291753-cpu-time
>>  - Comment from albertnetymk
>
> src/hotspot/share/gc/g1/g1FullCollector.hpp line 70:
> 
>> 68:   G1FullGCMark() : _gc_id(), _cpu_time() { }
>> 69: };
>> 70: 
> 
> I don't recall the exact reason for this, but I have a faint memory on having some discussion with its author. It's from https://bugs.openjdk.org/browse/JDK-8272651
> 
> Before this PR:
> 
> [32.328s][info ][gc          ] GC(47) Pause Young (Normal) (G1 Evacuation Pause) 1162M->1032M(3072M) 323.751ms
> [32.328s][info ][gc,cpu      ] GC(47) User=3.22s Sys=0.00s Real=0.33s
> ...
> [35.221s][info ][gc             ] GC(48) Pause Full (System.gc()) 1134M->660M(3072M) 2650.824ms
> [35.221s][info ][gc,cpu         ] GC(48) User=23.97s Sys=1.49s Real=2.65s
> 
> After this PR:
> 
> 
> [35.221s][info ][gc             ] GC(48) Pause Full (System.gc()) 1134M->660M(3072M) 2650.824ms
> [35.221s][info ][gc,cpu         ] GC(48) User=23.97s Sys=1.49s Real=2.65s
> ...
> [41.337s][info ][gc,cpu         ] GC(49) User=27.86s Sys=1.58s Real=3.28s
> [41.337s][info ][gc             ] GC(49) Pause Full (System.gc()) 1094M->660M(3072M) 3283.658ms
> 
> 
> Note that for Full-GC, the user/sys/real time is *before* GC-end, which is inconsistent with Young-GC.

Yes, I agree with you and fixed.
I was aware of this issue(and JDK-8272651) at the beginning so mentioned at the RFR above, but...

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

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


More information about the hotspot-jfr-dev mailing list