[PULL 00/10] Bitmaps patches

Eric Blake eblake at redhat.com
Tue Mar 17 15:49:28 UTC 2020


On 3/17/20 10:11 AM, Daniel P. Berrangé wrote:
> On Tue, Mar 17, 2020 at 03:07:34PM +0000, Peter Maydell wrote:
>> On Tue, 17 Mar 2020 at 15:05, Daniel P. Berrangé <berrange at redhat.com> wrote:
>>>
>>> On Tue, Mar 17, 2020 at 03:00:48PM +0000, Peter Maydell wrote:
>>>> On Tue, 17 Mar 2020 at 14:57, Daniel P. Berrangé <berrange at redhat.com> wrote:
>>>>> I don't feel like -Wno-unused-function looses anything significant, as
>>>>> the GCC builds will still be reporting unused functions which will
>>>>> catch majority of cases.
>>>>
>>>> The most interesting difference is that clang will catch unused
>>>> static inline functions which gcc does not.
>>>
>>> That's mostly just about dead code cruft detection IIUC. That code won't
>>> make it into the binary if it isn't used.
>>
>> Indeed, but it's nice to have the dead code cruft detection. You
>> can always mark the function as __attribute__((unused)) if you really
>> mean that it might be present but not used.
> 
> The *BSDs  seem to track latest glib pretty quickly. So if we got the
> unused attribute into upstream glib, we would probably have about
> 6-9 months before we get a build platform with the fixed glib included
> where we can conditionally re-enable the unused-function warning.

Looks like glib commit https://github.com/GNOME/glib/commit/b41bff1f 
(2.57.2) added G_GNUC_UNUSED to all of the functions declared during 
G_DEFINE_AUTOPTR_CLEANUP_FUNC.  Which version of glib is on the NetBSD 
machine?

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org




More information about the libvir-list mailing list