Skip to contentSkip to conversation

Build failure on Ubuntu 24.04 with Link Time Optimization (LTO)

DPDK/core Bug 1509 [email protected] 1 participant 2 messages Aug 4, 2024 – Jan 19

lore
Share & tools
lore
#0 lore raw

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

            Bug ID: 1509
           Summary: Build failure on Ubuntu 24.04 with Link Time
                    Optimization (LTO)
           Product: DPDK
           Version: 24.07
          Hardware: x86
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: core
          Assignee: [email protected]
          Reporter: [email protected]

Target Milestone: ---

$ meson --werror -Db_lto=true -Dc_args='-O3'
-Ddisable_drivers=net/ena,net/tap,*/octeontx,*/cnxk build && ninja -C build
[..]
[2453/2453] Linking target app/dpdk-test
In function ‘memcpy’,
    inlined from ‘test_argparse_copy’ at ../app/test/test_argparse.c:94:3,
    inlined from ‘test_argparse_init_obj’ at ../app/test/test_argparse.c:106:2,
    inlined from ‘test_argparse_invalid_basic_param’ at
../app/test/test_argparse.c:116:8:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:29:10: warning:
‘__builtin___memcpy_chk’ writing 48 bytes into a region of size 0 overflows the
destination [-Wstringop-overflow=]
[..]

OS: Ubuntu 24.04
Meson: 1.3.2
Compiler: gcc 13.2.0

(Note: some drivers are disabled because they report other errors)

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

http://bugs.dpdk.org/show_bug.cgi?id=1509

Stephen Hemminger ([email protected]) changed:

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

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

--- Comment #2 from Stephen Hemminger ([email protected]) --- commit 3fc246e883c412f3c285bcabdb402b7d66e78526

Author: Stephen Hemminger <[email protected]>
Date:   Tue Sep 9 06:49:52 2025 -0700

test/argparse: change initialization to workaround LTO

When compiled with Link Time Optimization, the existing code generated an error, because the compiler was unable to intuit that there was space in the flexible array.

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