On Tue, 17 May 2022 12:43:02 GMT, Yasumasa Suenaga <ysuen...@openjdk.org> wrote:

>> src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceIdBits.inline.hpp
>>  line 103:
>> 
>>> 101: PRAGMA_STRINGOP_OVERFLOW_IGNORED
>>> 102:   *dest = op(bits, *dest);
>>> 103: PRAGMA_DIAG_POP
>> 
>> I see no stringop here.  I'm still trying to understand what the compiler is 
>> complaining about.
>
> I guess GCC cannot understand `assert(dest != NULL` immediately preceding it.
> 
> 
> In file included from 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceIdLoadBarrier.inline.hpp:33,
>                  from 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceId.inline.hpp:30,
>                  from 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/support/jfrJdkJfrEvent.cpp:30:
> In function 'void set_form(jbyte, jbyte*) [with jbyte (* op)(jbyte, jbyte) = 
> traceid_or]',
>     inlined from 'void set(jbyte, jbyte*)' at 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceIdBits.inline.hpp:129:23,
>     inlined from 'static void JfrTraceIdBits::store(jbyte, const T*) [with T 
> = Klass]' at 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceIdBits.inline.hpp:135:6,
>     inlined from 'static void JfrTraceId::tag_as_jdk_jfr_event(const Klass*)' 
> at 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceId.inline.hpp:106:3,
>     inlined from 'static void JdkJfrEvent::tag_as(const Klass*)' at 
> /home/ysuenaga/github-forked/jdk/src/hotspot/share/jfr/support/jfrJdkJfrEvent.cpp:176:35:

I don't think this warning has anything to do with that NULL check. But I'm
still not understanding what it is warning about. The "region of size 0" part
of the warning message seems important, but I'm not (yet?) seeing how it could
be coming up with that.  The code involved here is pretty contorted...

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

PR: https://git.openjdk.java.net/jdk/pull/8646

Reply via email to