On Sun, Feb 06, 2022 at 10:44:47AM +0000, Peter Maydell wrote: > On Sun, 6 Feb 2022 at 09:29, Michael S. Tsirkin <m...@redhat.com> wrote: > > > > On Sat, Feb 05, 2022 at 09:05:12PM +0000, Peter Maydell wrote: > > > On the build-tsan and build-cfi-x86_64 jobs and also on macos > > > (this is a "clang is pickier than gcc about unused functions" one): > > > https://gitlab.com/qemu-project/qemu/-/jobs/2058536617 > > > https://gitlab.com/qemu-project/qemu/-/jobs/2058536571 > > > > > > ../tests/qtest/erst-test.c:91:20: error: unused function 'out_reg64' > > > [-Werror,-Wunused-function] > > > static inline void out_reg64(ERSTState *s, unsigned reg, uint64_t v) > > > ^ > > > > > > That's a weird one - it's static inline, compiler should not warn I > > think. compiler bug? I can drop this for sure but still. Is this > > what we should be doing? > > This is a gcc-vs-clang difference. gcc will not warn about any > unused "static inline" function. clang will not warn for them > in .h files but will warn for them in .c files. > > In this case clang is entirely correct -- the function is defined > and never used, not even conditionally depending on #ifdefs. > > thanks > -- PMM
I fixed it in pull v2, pls let me know. -- MST