RFR: 8352738: Implement JEP 520: JFR Method Timing and Tracing

Markus Grönlund mgronlun at openjdk.org
Fri May 23 13:53:58 UTC 2025


On Thu, 22 May 2025 11:48:52 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

>> Could I have a review of this enhancement that will add tracing capabilities to JFR? There are opportunities for performance improvements in the implementation, but I would rather add them later and separately.
>> 
>> Testing: tier 1-3, test/jdk/jdk/jfr
>> 
>> Thanks
>> Erik
>
> src/hotspot/share/jfr/support/methodtracer/jfrMethodTracer.cpp line 192:
> 
>> 190: }
>> 191: 
>> 192: static inline void log_add(const InstanceKlass* ik) {
> 
> Move it under `JfrMethodTracer::log_add` to avoid symbol clash later.

static functions, especially inlined ones, have internal linkage and will not cause global clashes.

> src/hotspot/share/jfr/support/methodtracer/jfrMethodTracer.cpp line 284:
> 
>> 282: static GrowableArray<jlong>* _current_unloaded_class_ids = nullptr;
>> 283: static GrowableArray<jlong>* _stale_class_ids = nullptr;
>> 284: static GrowableArray<jlong>* _empty_class_ids = nullptr;
> 
> Global symbols, move them under `JfrMethodTracer`?

static so not needed.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25306#discussion_r2104641697
PR Review Comment: https://git.openjdk.org/jdk/pull/25306#discussion_r2104643948


More information about the hotspot-jfr-dev mailing list