Debugging an efivar test failure (bug #1863475) leads to the discovery that variadic functions are missing the last variadic argument from their prototype definition in debgging data. Without -lfto option, foo() is decribe by GDB correctly: $ cat test.c #include <stdarg.h> void foo(int args, ...) { va_list ap; va_start(ap, args); va_end(ap); } $ gcc -fPIC -shared -o libtest.so -O0 -g test.c $ gdb libtest.so [...] Reading symbols from libtest.so... (gdb) info functions foo All functions matching regular expression "foo": File test.c: 2: void foo(int, ...); (gdb) quit But when compiling with -flto: $ gcc -fPIC -shared -o libtest.so -O0 -g -flto test.c $ gdb libtest.so [...] Reading symbols from libtest.so... (gdb) info functions foo All functions matching regular expression "foo": File <artificial>: 2: void foo(int); (gdb) quit The printed prototype is missing the last "..." argument. I believe this is only a problem in the debugging data, not in the generated code, as processing the variadic arguments in the foo() works as expected. Dissassembly also confirms it. This is probably not a bug in GDB, because abidw tool from libabigail package, which processs the debugging sections of ELF, also suffer from the same issue (as spotted in the efivar bug #1863475). My toolchain: $ rpm -q gcc binutils elfutils gcc-10.2.1-5.fc33.x86_64 binutils-2.35-11.fc33.x86_64 elfutils-0.181-1.fc33.x86_64
According to upstream bug report, this seems to have been fixed back in November 2020 (gcc 10.3 and 11.1) and in April 2021 (gcc 9.x and 8.x).
This message is a reminder that Fedora 33 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora 33 on 2021-11-30. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '33'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 33 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
I confirm it's fixed in gcc-11.2.1-1.fc34.