https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108968
David Malcolm <dmalcolm at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Last reconfirmed| |2023-03-02 Status|UNCONFIRMED |WAITING Ever confirmed|0 |1 --- Comment #8 from David Malcolm <dmalcolm at gcc dot gnu.org> --- I've attempted to work around this with the above patch (for gcc 13). As written, this ought to suppress the "uninit" false positive, but I didn't have a good kind of symbolic value to use for the resulting pointer, hence the analyzer will treat the result of get_cpu_info as an "unknowable" pointer, which might lead to a chain of follow-up false positives if there's logic in the code being analyzed that relies on dereferencing the result and getting consistent results. Can you attach a typical preprocessed source file from xen (the GPL licensed part) that was showing this (use -E), so I can poke at it to see how well this workaround works - thanks! Keeping open in case this needs further work, and to possibly track backporting to GCC 12.