Skip to contentSkip to conversation

examples/performance-thread meson build error with gcc12.1 on fedora36

Bug 1061 [email protected] 1 participant 2 messages Aug 1, 2022 – Aug 26, 2022

lore
Share & tools
lore
#0 lore raw

https://bugs.dpdk.org/show_bug.cgi?id=1061

Bug ID: 1061
Summary: [dpdk v21.11.2-rc1] examples/performance-thread meson
build error with gcc12.1 on fedora36
Product: DPDK
Version: 21.11
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: major
Priority: Normal
Component: core
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---

[DPDK Version]
dpdk stable v21.11.2-rc1

[OS version]
OS: Fedora Linux 36 (Server Edition)/Linux 5.17.7-300.fc36.x86_64
gcc: version 12.1.1 20220507

[Bad commit]
This is a problem on a new os.

[Test setup]
CC=gcc meson --werror -Denable_kmods=True -Dlibdir=lib -Dexamples=all --default-library=static gcc-linux-app
ninja -C gcc-linux-app

[Error log]
examples/performance-thread meson build error with gcc12.1 on fedora36 FAILED:
examples/dpdk-pthread_shim.p/performance-thread_pthread_shim_pthread_shim.c.o gcc -Iexamples/dpdk-pthread_shim.p -Iexamples -I../examples -Iexamples/performance-thread/pthread_shim -I../examples/performance-thread/pthread_shim -I../examples/performance-thread/common -I../examples/performance-thread/common/arch/x86 -I. -I.. -Iconfig -I../config -Ilib/eal/include -I../lib/eal/include -Ilib/eal/linux/include -I../lib/eal/linux/include -Ilib/eal/x86/include -I../lib/eal/x86/include -Ilib/eal/common -I../lib/eal/common -Ilib/eal -I../lib/eal -Ilib/kvargs -I../lib/kvargs -Ilib/metrics -I../lib/metrics -Ilib/telemetry -I../lib/telemetry -Ilib/mempool -I../lib/mempool -Ilib/ring -I../lib/ring -Ilib/net -I../lib/net -Ilib/mbuf -I../lib/mbuf -Ilib/ethdev -I../lib/ethdev -Ilib/meter -I../lib/meter -Ilib/cmdline -I../lib/cmdline -Ilib/timer -I../lib/timer -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Werror -O3 -include rte_config.h -Wextra -Wcast-qual -Wdeprecated -Wformat -Wformat-nonliteral -Wformat-security -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wold-style-definition -Wpointer-arith -Wsign-compare -Wstrict-prototypes -Wundef -Wwrite-strings -Wno-address-of-packed-member -Wno-packed-not-aligned -Wno-missing-field-initializers -Wno-zero-length-bounds -D_GNU_SOURCE -march=native -Wno-format-truncation -DALLOW_EXPERIMENTAL_API -MD -MQ examples/dpdk-pthread_shim.p/performance-thread_pthread_shim_pthread_shim.c.o -MF examples/dpdk-pthread_shim.p/performance-thread_pthread_shim_pthread_shim.c.o.d -o examples/dpdk-pthread_shim.p/performance-thread_pthread_shim_pthread_shim.c.o -c ../examples/performance-thread/pthread_shim/pthread_shim.c ../examples/performance-thread/pthread_shim/pthread_shim.c: In function ‘pthread_setspecific’:
../examples/performance-thread/pthread_shim/pthread_shim.c:592:27: error:
‘data’ may be used uninitialized [-Werror=maybe-uninitialized]

  592 |                 int rv =  lthread_setspecific((unsigned int)key, data);
      |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../examples/performance-thread/pthread_shim/pthread_shim.c:589:56: note:
accessing argument 2 of a function declared with attribute ‘access (none, 2)’
  589 | int pthread_setspecific(pthread_key_t key, const void *data)
      |                                            ~~~~~~~~~~~~^~~~

cc1: all warnings being treated as errors [3006/3142] Compiling C object examples/dpdk-l3fwd-thread.p/performance-thread_common_lthread_tls.c.o [3007/3142] Compiling C object examples/dpdk-simple_mp.p/multi_process_simple_mp_main.c.o [3008/3142] Compiling C object examples/dpdk-mp_client.p/multi_process_client_server_mp_mp_client_client.c.o [3009/3142] Compiling C object examples/dpdk-link_status_interrupt.p/link_status_interrupt_main.c.o [3010/3142] Compiling C object examples/dpdk-mp_server.p/multi_process_client_server_mp_mp_server_init.c.o [3011/3142] Compiling C object examples/dpdk-mp_server.p/multi_process_client_server_mp_mp_server_args.c.o [3012/3142] Compiling C object examples/dpdk-simple_mp.p/multi_process_simple_mp_mp_commands.c.o [3013/3142] Compiling C object drivers/libtmp_rte_event_octeontx2.a.p/event_octeontx2_otx2_worker.c.o [3014/3142] Compiling C object drivers/libtmp_rte_event_octeontx2.a.p/event_octeontx2_otx2_worker_dual.c.o
ninja: build stopped

Signature · 2 lines
You are receiving this mail because:
You are the assignee for the bug.
#1 lore raw

https://bugs.dpdk.org/show_bug.cgi?id=1061

huang chenyu ([email protected]) changed:

What |Removed |Added
----------------------------------------------------------------------------

             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED
                 CC|                            |[email protected]

--- Comment #2 from huang chenyu ([email protected]) --- Verified patchset 125a65cb03f845d1b6d5f7078670aa1a49d62513 on baseline LTS21.11.

Tested pass

Signature · 2 lines
You are receiving this mail because:
You are the assignee for the bug.