[PATCH] D35673: [analyzer] A better CFG-based suppress-on-sink.

2017-07-25 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added inline comments. Comment at: cfe/trunk/lib/StaticAnalyzer/Core/BugReporter.cpp:3313 +static bool isDominatedByNoReturnBlocks(const ExplodedNode *N) { + const CFG &Cfg = N->getCFG(); Do you really mean "is dominated by"? That is, "every path fro

[PATCH] D35673: [analyzer] A better CFG-based suppress-on-sink.

2017-07-25 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308957: [analyzer] Further improve suppress-on-sink behavior in incomplete analyses. (authored by dergachev). Changed prior to commit: https://reviews.llvm.org/D35673?vs=107871&id=108024#toc Repository

[PATCH] D35673: [analyzer] A better CFG-based suppress-on-sink.

2017-07-24 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 107871. NoQ added a comment. Reduce stack operations as Alexey suggested. https://reviews.llvm.org/D35673 Files: lib/StaticAnalyzer/Core/BugReporter.cpp test/Analysis/max-nodes-suppress-on-sink.c Index: test/Analysis/max-nodes-suppress-on-sink.c ==

[PATCH] D35673: [analyzer] A better CFG-based suppress-on-sink.

2017-07-21 Thread Aleksei Sidorin via Phabricator via cfe-commits
a.sidorin accepted this revision. a.sidorin added a comment. This revision is now accepted and ready to land. Just a minor nit. Comment at: lib/StaticAnalyzer/Core/BugReporter.cpp:3332 + +if (Visited.count(Blk)) { + // We've encountered a loop. We won't see anything ne

[PATCH] D35673: [analyzer] A better CFG-based suppress-on-sink.

2017-07-20 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. Because https://reviews.llvm.org/D28023 wasn't enough, as i've just seen an assertion-like macro with as many as 12 CFG blocks (including `do..while(false)` loops), i mocked up a quick CFG depth-first search to easily detect blocks dominated by noreturn blocks. http