Hello David, It would seem to me that a lot of the calling code like qemu_prealloc_mem for example should be sysemu-only, not used for tools, or user mode either right?
And the thread_context.c itself should also be sysemu-only, correct? Thanks, Claudio On 2/5/24 15:15, David Hildenbrand wrote: > On 05.02.24 11:14, Claudio Fontana wrote: >> Hi, > > Hi Claudio, > >> >> turning pages back in time, >> >> noticed that in recent qemu-img binaries we include an ELF dependency on >> libnuma.so that seems unused. >> >> I think it stems from this commit: >> >> commit 10218ae6d006f76410804cc4dc690085b3d008b5 >> Author: David Hildenbrand <da...@redhat.com> >> Date: Fri Oct 14 15:47:17 2022 +0200 >> >> util: Add write-only "node-affinity" property for ThreadContext >> >> >> possibly this hunk? >> >> diff --git a/util/meson.build b/util/meson.build >> index e97cd2d779..c0a7bc54d4 100644 >> --- a/util/meson.build >> +++ b/util/meson.build >> @@ -1,5 +1,5 @@ >> util_ss.add(files('osdep.c', 'cutils.c', 'unicode.c', >> 'qemu-timer-common.c')) >> -util_ss.add(files('thread-context.c')) >> +util_ss.add(files('thread-context.c'), numa) >> if not config_host_data.get('CONFIG_ATOMIC64') >> util_ss.add(files('atomic64.c')) >> endif >> >> >> I wonder if there is some conditional we could use to avoid the apparently >> useless dependency to libnuma in the qemu-img binary? > > the simplest change is probably moving the thread-context stuff out of > util (as you say, it's currently only used by QEMU itself). >