RFR: 8342818: Implement CPU Time Profiling for JFR [v2]
Johannes Bechberger
jbechberger at openjdk.org
Wed Oct 30 18:11:01 UTC 2024
On Wed, 30 Oct 2024 17:47:11 GMT, Johannes Bechberger <jbechberger at openjdk.org> wrote:
>> test/jdk/jdk/jfr/event/metadata/TestLookForUntestedEvents.java line 92:
>>
>>> 90: // Experimental events
>>> 91: private static final Set<String> experimentalEvents = Set.of(
>>> 92: "Flush", "SyncOnValueBasedClass", "CPUTimeSample", "CPUTimeSampleLoss");
>>
>> The reason we added an exclusion list for experimental events is so developers wouldn't be forced to write a test. Since you have a test for the CPUTimeSample event, I think you can remove it.
>>
>> (If TestLookForUntestedEvents is not able to find the event test, write the event name in the test)
>
> But this leads to fails, because of the loop that initialized the `jfrEventTypes`:
>
> for (EventType type : FlightRecorder.getFlightRecorder().getEventTypes()) {
> if (type.getAnnotation(Experimental.class) == null) {
> jfrEventTypes.add(type.getName().replace("jdk.", ""));
> }
> }
>
> Only events that not experimental are included. But `CPUTimeSample` is experimental.
I update the test to check for CPUTimeSample events
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20752#discussion_r1823151510
More information about the hotspot-dev
mailing list