https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98901
Bug ID: 98901 Summary: Static analyses warning disappears when the value is passed to a function with variable number of arguments when optimisation is on Product: gcc Version: 8.3.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: oleg.pekar.2017 at gmail dot com Target Milestone: --- Created attachment 50096 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=50096&action=edit Preprocessor output for source file test2.c The problem is related to bug 98900 gcc version: 8.3.1 system type: RedHat 8.1, Kernel 4.18.0-147.3.1.el8_1.x86_64 Problem: The same static analyses warning seen in bug 98900 disappears when the pointer variable that keeps address of the local variable from problem in the bug 98900 is used for the first time in function with variable number of parameters (must have optimisation on, as continuation of problem 1) Input source: attached test2.i Command line: gcc -Wall -save-temps -O2 test2.c Output when call to f4() is present in main(): nothing Output when call to f4() is commented in main(): test2.c: In function ‘main’: test2.c:29:13: warning: ‘x’ is used uninitialized in this function [-Wuninitialized] int x = 0; ^