[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-28 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Then the current solution is good, print always end of the bug path. A change to the bug reporting component was made that caused reported position of bugs to change. New is the end of the path, old is the location set by the checker (`BugReport::getLocation` value).

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-28 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I believe i clarified above how this checker should work. For testing purposes (which is the only reason to ever use the minimal output) i prefer to have it at the end of path, because that tells more about the bug path and therefore more important to test. The question

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-27 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. From the beginning on in this patch I assumed that the location of the bug report should be the end of the bug path. But this is probably a wrong approach, specially if the bug report has uniqueing location. In that case the uniqueing location may be a better place

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-24 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D83961#2166903 , @balazske wrote: > Every other test failure comes from RetainCount checker except > //malloc-plist.c//. Aha, ok. So, anyway, for retain count checker we ultimately only care about plist and html reports, not

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-23 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 280149. balazske added a comment. Change column in malloc-plist test because code was reformatted. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83961/new/ https://reviews.llvm.org/D83961 Files:

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-22 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Every other test failure comes from RetainCount checker except //malloc-plist.c//. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83961/new/ https://reviews.llvm.org/D83961

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-22 Thread Balázs Kéri via Phabricator via cfe-commits
balazske marked an inline comment as done. balazske added inline comments. Comment at: clang/test/Analysis/malloc-plist.c:137-139 if (y) -y++; -}//expected-warning{{Potential leak}} + y++; //expected-warning{{Potential leak}} +} NoQ wrote: >

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-21 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/test/Analysis/CGColorSpace.c:8-11 void f() { - CGColorSpaceRef X = CGColorSpaceCreateDeviceRGB(); // expected-warning{{leak}} + CGColorSpaceRef X = CGColorSpaceCreateDeviceRGB(); CGColorSpaceRetain(X); +} //

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-20 Thread Balázs Kéri via Phabricator via cfe-commits
balazske marked an inline comment as done. balazske added a comment. The problem in D83120 is fixed by this patch. What I figured out from the code is that `BugReporter::FlushReport` calls `findReportInEquivalenceClass` that returns a report that has not

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-20 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. I find the summary here a bit lacking. We detected this issue in D83120 , where a lot of discussion can be found, so its worth linking in. On its own, I'm not immediately sold on whether this is the correct solution, and even if it

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-17 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Big part of the test failures is with the `osx.cocoa.RetainCount` checker. Only a small part of the errors is fixed now. Comment at: clang/lib/Analysis/PathDiagnostic.cpp:369 +} + } if (X.getBugType() != Y.getBugType()) This

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-17 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 278742. balazske marked an inline comment as done. balazske added a comment. Fixed some source location changes in tests. Re-added check for empty path. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83961/new/

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-16 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. > These will be updated if the code change looks good. Hard to tell; this entire code is too convoluted, i'd rather look at the changes. Can you update at least some tests? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-16 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Lot of tests are failing because changed warning locations. These will be updated if the code change looks good. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83961/new/ https://reviews.llvm.org/D83961

[PATCH] D83961: [Analyzer] Fix bug report source locations in minimal output.

2020-07-16 Thread Balázs Kéri via Phabricator via cfe-commits
balazske created this revision. Herald added subscribers: cfe-commits, ASDenysPetrov, martong, Charusso, gamesh411, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: clang. Fix of the