[PATCH] D53076: [analyzer] WIP: Enhance ConditionBRVisitor to write out more information

Csaba Dabis via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Oct 10 11:50:40 PDT 2018


Charusso added subscribers: baloghadamsoftware, whisperity.
Charusso added a comment.

In https://reviews.llvm.org/D53076#1260663, @george.karpenkov wrote:

> The change makes sense to me, but:
>
> 1. Note that "Assuming X" directives are useful for the analyzer developers, since they know that's where the checker makes arbitrary assumptions, but to end users that mostly feels like noise ("Taking true branch" is there already, why there should be "Assuming 'i' is > 0" as well?)
> 2. @NoQ do you know why the GDM comparison was there in the first place? The commit was made by Ted in 2011, maybe constraint changes had to be reflected in the GDM at that point (?)


Based on @baloghadamsoftware's idea (https://reviews.llvm.org/D34508) the main goal is to print out trivial values for the Clang SA, but lot of time consuming nonsense for developers. As you mentioned it is bad to have multiple assumptions, but half of the reporters behave like that, and the other half does not print any/useful information.

That two separate project based on that current project: **create** the reports, and make the style identical, so that we could enhance them. The best example here is `test/Analysis/diagnostics/macros.cpp`: on line 27 you could see the message `Assuming the condition is true` but the upper conditions miss this report.


https://reviews.llvm.org/D53076





More information about the cfe-commits mailing list