RFR: 8282420: JFR: Remove event handlers [v6]
Doug Simon
dnsimon at openjdk.org
Wed Jul 6 20:28:45 UTC 2022
On Wed, 6 Jul 2022 19:49:58 GMT, Erik Gahlin <egahlin at openjdk.org> wrote:
>> src/hotspot/share/jfr/instrumentation/jfrResolution.hpp line 40:
>>
>>> 38: public:
>>> 39: static void on_runtime_resolution(const CallInfo & info, TRAPS);
>>> 40: static void on_c1_resolution(const GraphBuilder * builder, const ciKlass * holder, const ciMethod * target);
>>
>> Should the declarations of `on_c1_resolution` and `on_c2_resolution` be guarded with `COMPILER2_PRESENT` and `COMPILER1_PRESENT` since the method bodies are?
>
> Yes. It's been fixed. See:
> https://github.com/openjdk/jdk/pull/8680
Yes, I see the bodies are guarded. I was referring to the declarations here in `jfrResolution.hpp`. Shouldn't it be something like:
#ifdef COMPILER1
static void on_c1_resolution(const GraphBuilder * builder, const ciKlass * holder, const ciMethod * target);
#endif
#ifdef COMPILER2
static void on_c2_resolution(const Parse * parse, const ciKlass * holder, const ciMethod * target);
#endif
and likewise in `jfr.hpp`:
#ifdef COMPILER2
static void on_resolution(const Parse* parse, const ciKlass* holder, const ciMethod* target);
#endif
#ifdef COMPILER1
static void on_resolution(const GraphBuilder* builder, const ciKlass* holder, const ciMethod* target);
#endif
-------------
PR: https://git.openjdk.org/jdk/pull/8383
More information about the hotspot-jfr-dev
mailing list