[Bug analyzer/115089] -Wanalyzer-use-of-uninitialized-value false negative due to overzealous state merging

2024-05-15 Thread dmalcolm at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115089 David Malcolm changed: What|Removed |Added Ever confirmed|0 |1 Summary|-Wanalyzer-use-of-

[Bug analyzer/115089] -Wanalyzer-use-of-uninitialized-value false negative

2024-05-14 Thread alx at kernel dot org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115089 --- Comment #4 from Alejandro Colomar --- Thanks, David! I'm happy that this might help improve the analyzer. :-)

[Bug analyzer/115089] -Wanalyzer-use-of-uninitialized-value false negative

2024-05-14 Thread dmalcolm at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115089 --- Comment #3 from David Malcolm --- FWIW, adding -fno-analyzer-state-merge makes it find the issue; see https://godbolt.org/z/Ecfe9oqjv : In function 'main': :16:16: warning: use of uninitialized value 'x' [CWE-457] [-Wanalyzer-use-of-uniniti

[Bug analyzer/115089] -Wanalyzer-use-of-uninitialized-value false negative

2024-05-14 Thread alx at kernel dot org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115089 --- Comment #2 from Alejandro Colomar --- I found that Clang's analyzer finds this bug, so I'm less concerned that GCC can't find it. Feel free to ignore it if it's too hard to fix. ;) $ clang-tidy ./bug.c Error while trying to load a compi

[Bug analyzer/115089] -Wanalyzer-use-of-uninitialized-value false negative

2024-05-14 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115089 Andrew Pinski changed: What|Removed |Added See Also||https://gcc.gnu.org/bugzill