On Wed, Jul 17, 2024 at 2:32 PM Siteshwar Vashisht <svashisht@xxxxxxxxxx> wrote: > > On Wed, Jul 10, 2024 at 1:30 AM Daniel P. Berrangé <berrange@xxxxxxxxxx> wrote: > > > > On Tue, Jul 09, 2024 at 04:03:10PM -0400, David Malcolm wrote: > > > On Tue, 2024-07-09 at 13:37 +0200, Siteshwar Vashisht wrote: > > > > On Tue, Jul 9, 2024 at 1:16 PM Daniel P. Berrangé > > > > <berrange@xxxxxxxxxx> > > > > wrote: > > > > > > > > > For packages I'm involved in (QEMU, libvirt), there are a huge > > > > > number of > > > > > reported "flaws". The false positive error reports level is way too > > > > > high > > > > > for me to spend time looking at these reports in any detail though. > > > > > > > > > > The biggest problem is that the clang 'warning[unix.Malloc]' check > > > > > doesn't > > > > > understand that __attribute__((cleanup)) functions (via the glib > > > > > g_autofree > > > > > / g_autoptr macros) will free memory. On libvirt this accounts for > > > > > 35% of > > > > > all warnings list, and QEMU it accounts for about 20% of warnings. > > > > > There > > > > > are probably some real memory leaks there, but it is impractical to > > > > > search > > > > > for them amongst the noise. > > > > > > I don't know about the clang analyzer, but FWIW GCC's -fanalyzer has > > > code to handle __attribute__((cleanup)) and thus shouldn't have this > > > issue (see e.g. upstream bug > > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108733 ). But there's > > > certainly other bugs in -fanalyzer that it could be running into. > > > > Yeah, in the openscanhub reports, the bogus memory leaks appear > > to be from CLang rather than GCC. > > > > > > > Another 30% are "DeadStore" warnings which, while correct, are also > > > > > harmless > > > > > and not something we intend to fix since this is generated code & > > > > > making > > > > > the > > > > > generator more complex is not desired. > > > > > > > > > > > Which analyzer is emitting that? > > > > This was again CLang. > > I plan to disable Clang during the next mass scan to decrease the > number of false positives in the report. Thanks! I have already disabled it, so you should see less noise in the reports. Thanks for the feedback! > > > > > > > With regards, > > Daniel > > -- > > |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| > > |: https://libvirt.org -o- https://fstop138.berrange.com :| > > |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :| > > > > -- > > _______________________________________________ > > devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx > > To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx > > Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > > List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx > > Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue -- _______________________________________________ devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue