RFR 8247471: Enhance CPU load events with the actual elapsed CPU time

Erik Gahlin erik.gahlin at oracle.com
Mon Jun 15 08:18:35 UTC 2020


Hi Jaroslav,

I wonder if we should remove CPU from the field names and labels in metadata.xml

<Field type="long" contentType="nanos" name="jvmUserCpuTime" label="Elapsed JVM UserTime”/>

becomes

<Field type="long" contentType="nanos" name="jvmUserTime" label="Elapsed JVM User Time”/>

CPU is implicit from the event name and we don’t have it for the other fields.

When does machineTotalCpuTime start? 

From when the machine booted or when the JVM process started? 

Maybe we want to make that clear in a description.

Erik

> On 12 Jun 2020, at 12:08, Jaroslav Bachorík <jaroslav.bachorik at datadoghq.com> wrote:
> 
> Hi all,
> 
> Here is my attempt at adding the elapsed CPU time to
> ThreadCPULoadEvent and CPULoadEvent JFR events.
> 
> I have tested the implementation on Linux, MacOS and Windows and it is
> working as expected.
> However, I am not an expert on all of those platforms so if there is
> an easier way to get the elapsed CPU time than what I am doing now I
> am open to suggestions.
> 
> JIRA: https://bugs.openjdk.java.net/browse/JDK-8247471
> Webrev: http://cr.openjdk.java.net/~jbachorik/8247471
> 
> Thanks!
> 
> -JB-



More information about the hotspot-jfr-dev mailing list