[PATCH] D57891: [analyzer] Fix infinite recursion in printing macros

2019-03-08 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL355705: [analyzer] Fix infinite recursion in printing macros (authored by Szelethus, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-09 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Herald added a subscriber: whisperity. This patch no longer applies cleanly to the latest version of clang -- could you rebase please? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57893/new/ https://reviews.llvm.org/D57893

[PATCH] D58777: [analyzer] Fix an assertation failurure for invalid sourcelocation, add a new debug checker

2019-03-09 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D58777#1422248 , @NoQ wrote: > Very nice! Crashing diagnostic locations are a fairly common issue. That > said, this still makes me wonder what sort of checker were you writing that > triggered this originally :) Unfortuna

[PATCH] D58573: [analyzer] Move UninitializedObject out of alpha

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D58573#1422198 , @NoQ wrote: > Also, hmm, how about the following heuristics (looked at the positive in > `rtags` and thought about this): > > - if the field is public, don't warn (the structure seems to be used simply > as

[PATCH] D57922: [analyzer] Insert checker options into AnalyzerOption::ConfigTable

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190021. Szelethus added a comment. Removed every piece of code not directly related to inserting checker option to the config table, moving it to a new patch. This essentially restores the revision to it's earliest state, except that it's even simpler: no

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked 2 inline comments as done. Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp:371 +// We can't get away with binaryFind here, as it uses lower_bound. +auto CheckerIt = llvm::find(Checkers, CheckerInfo(SuppliedChec

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190022. Szelethus marked an inline comment as done. Szelethus added a comment. Adding `explicit` to `CheckerInfo`'s constructor. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57855/new/ https://reviews.llvm.org/D57855 Files: include/clang/Basic

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190023. Szelethus added a comment. Herald added subscribers: Charusso, jdoerfert. Refactored the entire patch, NFC compared to the earlier diff. This was needed as in a followup revision, much of the code would be rewritten. CHANGES SINCE LAST ACTION ht

[PATCH] D59195: [analyzer] Remove the default value arg from getChecker*Option

2019-03-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, baloghadamsoftware, xazax.hun, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, jdoerfert, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. Herald added a revi

[PATCH] D58065: [analyzer] Document the frontend library

2019-03-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a reviewer: aaron.ballman. Szelethus added a comment. Oops. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58065/new/ https://reviews.llvm.org/D58065 ___ cfe-commits mailing list cfe-commits@lists.llvm

[PATCH] D59054: [analyzer] C++17: PR40022: Support aggregate initialization with compound values in presence of base classes.

2019-03-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. LGTM! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59054/new/ https://reviews.llvm.org/D59054 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190223. Szelethus marked 13 inline comments as done. Szelethus added a comment. Fixes according to reviewer comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57855/new/ https://reviews.llvm.org/D57855 Files: include/clang/Basic/Diagnostic

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: include/clang/StaticAnalyzer/Frontend/CheckerRegistry.h:156 + return FullName == Rhs.FullName; +} + baloghadamsoftware wrote: > Are we able now to distinguish checkers of the same short names but in > differe

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC355903: [analyzer] Fix function macro crash (authored by Szelethus, committed by ). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57893/new/ https://reviews.llvm.org/D5789

[PATCH] D57890: [analyzer] Fix in self assignment checker

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus requested changes to this revision. Szelethus added a comment. This revision now requires changes to proceed. Herald added subscribers: Charusso, jdoerfert, whisperity. Yup, I agree. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57890/new/ https://revie

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked 2 inline comments as done. Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp:340 + if (OptionType == "bool") { +if (SuppliedValue != "true" && SuppliedValue != "false") { + if (AnOpts.ShouldEmitErrorsOnInvalidC

[PATCH] D58367: [analyzer] NFC: Improve upon the concept of BugReporterVisitor.

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Would `NoteTag`s be displayed in a dumped exploded graph? In D58367#1405185 , @NoQ wrote: > In D58367#1404722 , @Charusso wrote: > > > So with that, I would out-chain this patch from the

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus reopened this revision. Szelethus added a comment. This revision is now accepted and ready to land. Ugh. Reverted the patch. FAIL: Clang :: Analysis/plist-macros-with-expansion.cpp (720 of 14281) TEST 'Clang :: Analysis/plist-macros-with-expansion.cpp' FAILED *

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus requested changes to this revision. Szelethus added a comment. This revision now requires changes to proceed. Let's investigate what's behind this. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57893/new/ https://reviews.llvm.org/D57893 _

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-12 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Some bots also break but emit a different message: TEST 'Clang :: Analysis/plist-macros-with-expansion.cpp' FAILED Script: -- : 'RUN: at line 1'; /b/sanitizer-x86_64-linux-bootstrap/build/llvm_build_asan/bin/clang -c

[PATCH] D59279: [Analyzer] Checker for non-determinism caused by iteration of unordered container of pointers

2019-03-13 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus requested changes to this revision. Szelethus added a reviewer: baloghadamsoftware. Szelethus added a comment. This revision now requires changes to proceed. Code is great, idea's great, so green light on my part, but maybe we should allow some folks who are more knowledgeable on AST ma

[PATCH] D59279: [Analyzer] Checker for non-determinism caused by iteration of unordered container of pointers

2019-03-13 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D59279#1427017 , @mgrang wrote: > 3. Currently, we also do not check for what happens inside the for loop. > Not all iterations may causes non-determinism. For example, counting or > summing up the elements should not be n

[PATCH] D59279: [Analyzer] Checker for non-determinism caused by iteration of unordered container of pointers

2019-03-13 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Could you please add a commit that changes the top of the file on your previous commit? Feel free to do that without review (I can't commit it myself atm). In D59279#1427803 , @mgrang wrote: > Also, what is the difference betwe

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-13 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Ah so it was a past-the-end iterator dereference error. Cheers! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57893/new/ https://reviews.llvm.org/D57893

[PATCH] D57893: [analyzer] Fix function macro crash

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL356142: [analyzer] Fix function macro crash (authored by Szelethus, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.o

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked 3 inline comments as done. Szelethus added a comment. > Let's put at least a FIXME here that the documentation for this option was > missing. I'd prefer to just simply fix this. @NoQ, could you help us fill in the gaps? We need a desctiption for - `nullability:NoDiagnoseCallsT

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190625. Szelethus edited the summary of this revision. Szelethus added a comment. Herald added subscribers: Charusso, jdoerfert. Also, don't forget package options :^) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57858/new/ https://reviews.llvm.o

[PATCH] D57922: [analyzer] Insert checker options into AnalyzerOption::ConfigTable

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190628. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57922/new/ https://reviews.llvm.org/D57922 Files: include/clang/StaticAnalyzer/Frontend/CheckerRegistry.h lib/StaticAnalyzer/Core/AnalyzerOptions.cpp lib/StaticAnalyzer/Frontend/CheckerReg

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190629. Szelethus marked 6 inline comments as done. Szelethus added a comment. Fixes according to inline comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57860/new/ https://reviews.llvm.org/D57860 Files: include/clang/Basic/DiagnosticDri

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190630. Szelethus added a comment. Add a testcase for packages. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57860/new/ https://reviews.llvm.org/D57860 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/StaticAnalyzer/Frontend

[PATCH] D58777: [analyzer] Fix an assertation failurure for invalid sourcelocation, add a new debug checker

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190643. Szelethus marked 7 inline comments as done. Szelethus added a comment. Fixes according to inline comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58777/new/ https://reviews.llvm.org/D58777 Files: docs/analyzer/developer-docs/Debu

[PATCH] D58777: [analyzer] Fix an assertation failurure for invalid sourcelocation, add a new debug checker

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Checkers/DebugCheckers.cpp:271 +//===--===// +// Emits a report for each and every Stmt. +//===-

[PATCH] D58777: [analyzer] Fix an assertation failurure for invalid sourcelocation, add a new debug checker

2019-03-14 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC356161: [analyzer] Fix an assertation failure for invalid sourcelocation, add a new… (authored by Szelethus, committed by ). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D5

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-15 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus planned changes to this revision. Szelethus marked 3 inline comments as done. Szelethus added a comment. Alright, I'll de-clutter this patch a bit. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57855/new/ https://reviews.llvm.org/D57855 _

[PATCH] D59458: [analyzer][NFC] Clang-format CheckerRegistry

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, baloghadamsoftware, xazax.hun, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. Repository: rC Clang https

[PATCH] D59457: [analyzer][NFC] Use capital variable names in CheckerRegistry

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, baloghadamsoftware, xazax.hun, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, jdoerfert, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, mgrang, szepet, whisperity. There are

[PATCH] D59459: [analyzer][NFC] Prefer binary searches in CheckerRegistry

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: xazax.hun, NoQ, baloghadamsoftware, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. Szelethus added a parent revis

[PATCH] D59461: [analyzer] Fix an assertion failure if plugins added dependencies

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, xazax.hun, baloghadamsoftware, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity. Szelethus added a parent revis

[PATCH] D59461: [analyzer] Fix an assertion failure if plugins added dependencies

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Don't let the testcase fool you, it's merely added because there wasn't any for that particular case, I still need to add the plugin, but that moves quite a few files around, so I might separate that to another patch. Repository: rC Clang CHANGES SINCE LAST ACTION

[PATCH] D57855: [analyzer] Reimplement checker options

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190977. Szelethus edited the summary of this revision. Szelethus added a comment. - Moved every non-related change to smaller patches, this should ease **a lot** on reviewers. - Now processing options once all checkers are added to the registry. This is im

[PATCH] D57922: [analyzer] Insert checker options into AnalyzerOption::ConfigTable

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190979. Szelethus added a comment. Rebase. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57922/new/ https://reviews.llvm.org/D57922 Files: lib/StaticAnalyzer/Core/AnalyzerOptions.cpp lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp test/Anal

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190981. Szelethus added a comment. Rebase. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57860/new/ https://reviews.llvm.org/D57860 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/StaticAnalyzer/Frontend/CheckerRegistry.h

[PATCH] D59464: [analyzer] Add an example plugin for checker dependency handling

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, xazax.hun, rnkovacs, baloghadamsoftware. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity, mgorny. - Move `examples/anal

[PATCH] D59465: [analyzer] Add example plugin for checker option handling

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, xazax.hun, rnkovacs, baloghadamsoftware. Szelethus added a project: clang. Herald added subscribers: cfe-commits, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, whisperity, mgorny. Repository: rC Clan

[PATCH] D57922: [analyzer] Insert checker options into AnalyzerOption::ConfigTable

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190991. Szelethus added a comment. Add a test case for checker plugins. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57922/new/ https://reviews.llvm.org/D57922 Files: lib/StaticAnalyzer/Core/AnalyzerOptions.cpp lib/StaticAnalyzer/Frontend/Ch

[PATCH] D59195: [analyzer] Remove the default value arg from getChecker*Option

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190993. Szelethus added a comment. Rebase. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59195/new/ https://reviews.llvm.org/D59195 Files: include/clang/StaticAnalyzer/Core/AnalyzerOptions.h lib/StaticAnalyzer/Checkers/AnalysisOrderChecker.cp

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190992. Szelethus added a comment. Add a test case for checker plugins. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57860/new/ https://reviews.llvm.org/D57860 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/StaticAnalyzer/

[PATCH] D59195: [analyzer] Remove the default value arg from getChecker*Option

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190996. Szelethus added a comment. Remove the default argument from the plugin, also add a test case for it. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59195/new/ https://reviews.llvm.org/D59195 Files: examples/StaticAnalyzer/OptionHandlingP

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-03-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 190997. Szelethus added a comment. Add a test case for then checker plugin. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57858/new/ https://reviews.llvm.org/D57858 Files: include/clang/Driver/CC1Options.td include/clang/StaticAnalyzer/Core/A

[PATCH] D59457: [analyzer][NFC] Use capital variable names, move methods out-of-line, rename some in CheckerRegistry

2019-03-19 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D59457#1433180 , @baloghadamsoftware wrote: > Please rename the patch. Its name does not really express its content. Good point, sorry about that. In D59457#1433816 , @xazax.hun wro

[PATCH] D59516: [analyzer] Make GenericTaintChecker configurable

2019-03-19 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus requested changes to this revision. Szelethus added a comment. This revision now requires changes to proceed. I'm very much guilty of doing functional and refactoring changes within the same patch, but I think working on `GenericTaintChecker` AND in the same patch doing (seemingly unre

[PATCH] D58573: [analyzer] Move UninitializedObject out of alpha

2019-03-21 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping, @NoQ, if we settled on `optin.cplusplus`, would you be fine with this patch? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58573/new/ https://reviews.llvm.org/D58573 ___ cfe-commits

[PATCH] D59279: [Analyzer] Checker for non-determinism caused by iteration of unordered container of pointers

2019-03-22 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D59279#1438514 , @mgrang wrote: > Although, as you rightly pointed out that //ordered// sets of pointers are as > non-deterministic as //unordered// ones. What if you store pointers to the elements of an array? In that case

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-03-23 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D57860#1432728 , @dcoughlin wrote: > I think it would be better if the default for compatibility mode were 'true'. > That way this change will be backwards compatible and clients who want to > enforce stricter checking could

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-03-23 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. This patch isn't intended for end users, which is why `-analyzer-checker-option-help` is a frontend flag -- besides, some of the plain frontend flags aren't either. It is purely for development purposes, though exposing an end user friendly subset of these through a d

[PATCH] D59465: [analyzer] Add example plugin for checker option handling

2019-03-23 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Would you be more comfortable with this patch I didn't touch the examples folder? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59465/new/ https://reviews.llvm.org/D59465 ___ cfe-commits m

[PATCH] D59555: [analyzer] Add yaml parser to GenericTaintChecker

2019-03-25 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. I think the idea is awesome, thanks! We really need to not use `UINT_MAX`, and I think `static` fields and member functions are a bit overused in this patch -- can't we just make `getConfiguration` and `parseConfiguration` static non-member functions, and make them t

[PATCH] D59516: [analyzer] Add custom filter functions for GenericTaintChecker

2019-03-25 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus requested changes to this revision. Szelethus added a comment. This revision now requires changes to proceed. Same thing. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59516/new/ https://reviews.llvm.org/D59516 ___ cfe-commits mai

[PATCH] D59279: [Analyzer] Checker for non-determinism caused by iteration of unordered container of pointers

2019-03-26 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Other than that, LGTM, thanks! Please, again, let @NoQ have the final say. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59279/new/ https://reviews.llvm.org/D59279 __

[PATCH] D59555: [analyzer] Add yaml parser to GenericTaintChecker

2019-03-26 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D59555#1442331 , @boga95 wrote: > Why is it better not to use `static` functions/variables? Has it any > performance impact? I don't think so, I just think that it's easier to follow what's happening with a non-static fiel

[PATCH] D59555: [analyzer] Add yaml parser to GenericTaintChecker

2019-03-26 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp:73-75 static const unsigned InvalidArgIndex = UINT_MAX; /// Denotes the return vale. static const unsigned ReturnValueIndex = UINT_MAX - 1; boga95 wrote: > S

[PATCH] D58367: [analyzer] NFC: Improve upon the concept of BugReporterVisitor.

2019-03-27 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. Amazing work! Thanks! In D58367#1443783 , @NoQ wrote: > Remove memoization for now. Address a few inline comments. I'm mostly done > with this first patch, did i accidentally miss anything? > >

[PATCH] D59457: [analyzer][NFC] Use capital variable names, move methods out-of-line, rename some in CheckerRegistry

2019-03-27 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59457/new/ https://reviews.llvm.org/D59457 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman

[PATCH] D59901: [analyzer] PR41239: Fix a crash on invalid source location in NoStoreFuncVisitor.

2019-03-28 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. An assert would be real nice in `SourceManager`, we should definitely add that, since some callbacks don't even receive a `CallEvent` object. My checker runs on `checkPostCall`, and also checks where fields lie in a system header. Re

[PATCH] D59861: [analyzer] NFC: Replace Taint API with a usual inter-checker communication API?

2019-03-28 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. > "putting all such stuff into the `ProgramState` class clearly doesn't scale, > but we still didn't come up with anything better, so let's just put it in the > header and see if a better design suddenly emerges in the future after we

[PATCH] D59934: Compare SourceLocations from different TUs by FileID

2019-03-28 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a reviewer: Szelethus. Szelethus added a comment. In D59934#1446051 , @gamesh411 wrote: > Hi! > > This issue came up during the generation BugReports of BugPaths containing > macro-expansions, where the spelling location and expansion loca

[PATCH] D59861: [analyzer] NFC: Replace Taint API with a usual inter-checker communication API?

2019-03-29 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Also, you might as well clang-format the new files, since we already messed with git blame. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59861/new/ https://reviews.llvm.org/D59861 ___ cfe-commits mailing list cf

[PATCH] D58573: [analyzer] Move UninitializedObject out of alpha

2019-03-29 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping^2 Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58573/new/ https://reviews.llvm.org/D58573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[PATCH] D59934: Compare SourceLocations from different TUs by FileID

2019-03-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. I would still like to learn more about this issue. I am somewhat afraid that the our macro expansion is faulty. Can you provide a stacktrace maybe? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59934/new/ https://reviews.llvm.org/D5993

[PATCH] D59934: Compare SourceLocations from different TUs by FileID

2019-03-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a subscriber: bruntib. Szelethus added a comment. Hmm. Is your clang recent enough to contain @bruntib's patch D57892 ? Is it possible that this patch solves the same issue? With this patch applied, are you able to get a macro expansions from a d

[PATCH] D58573: [analyzer] Move UninitializedObject out of alpha

2019-04-02 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. One heuristic that we could use is to ignore inherited data members optionally. Does that sound any good? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58573/new/ https://reviews.llvm.org/D58573 _

[PATCH] D60112: [analyzer] Treat write into a top-level parameter variable with destructor as escape.

2019-04-02 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Woah, the code looks amazing, cheers on the refactoring! I'll be honest, I'm struggling a bit with the sentence "we're now in the top frame". In order, I don't understand what does - we - now - in the top frame mean. "Top-level argument" is another one -- Do we have

[PATCH] D60110: [analyzer] When failing to evaluate a __builtin_constant_p, presume it's false.

2019-04-02 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. LGTM! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60110/new/ https://reviews.llvm.org/D60110 ___ cfe-com

[PATCH] D60281: [analyzer] Add docs for cplusplus.InnerPointer

2019-04-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Woohoo! Comment at: docs/analyzer/checkers.rst:225-226 +``std::string``s, by recognizing member functions that may re/deallocate the buffer +before use. In the future,

[PATCH] D59555: [analyzer] Add yaml parser to GenericTaintChecker

2019-04-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. We agreed to disagree on the static function stuff -- it doesn't really matter, and I don't insist. I have no objections against this patch, great job! I won't formally accept to make it stand out a little more. Thanks! CHANGES SINCE LAST ACTION https://reviews.llv

[PATCH] D60112: [analyzer] Treat write into a top-level parameter variable with destructor as escape.

2019-04-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Okay, I played around with this patch, I see now where this is going! LGTM! > Do you think i should document it somehow? Aye, the description you gave was enlightening, thanks! If you ca

[PATCH] D59555: [analyzer] Add yaml parser to GenericTaintChecker

2019-04-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Sorry, I rushed my earlier comment -- I definitely think that we should get rid of the `UINT_MAX` thing before landing this. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59555/new/ https://reviews.llvm.org/D59555 __

[PATCH] D60281: [analyzer] Add docs for cplusplus.InnerPointer

2019-04-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: docs/analyzer/checkers.rst:225-226 +``std::string``s, by recognizing member functions that may re/deallocate the buffer +before use. In the future, it would be great to add support for other STL and +non-STL containers, and most notab

[PATCH] D58367: [analyzer] NFC: Improve upon the concept of BugReporterVisitor.

2019-04-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Hmmm, interesting. Could there be an issue with `NoteTag` not being trivially destructible? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58367/new/ https://reviews.llvm.org/D58367

[PATCH] D59121: [analyzer] Fix macro names in diagnostics within bigger macros.

2019-04-10 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. LGTM! Thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59121/new/ https://reviews.llvm.org/D59121 ___ cfe-commits mailing lis

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-04-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57860/new/ https://reviews.llvm.org/D57860 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-04-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57858/new/ https://reviews.llvm.org/D57858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D59465: [analyzer] Add example plugin for checker option handling

2019-04-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus planned changes to this revision. Szelethus added a comment. I'll move this, and the already existing plugin to test/ or unittest/. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59465/new/ https://reviews.llvm.org/D59465 _

[PATCH] D58573: [analyzer] Move UninitializedObjectChecker out of alpha

2019-04-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 194667. Szelethus retitled this revision from "[analyzer] Move UninitializedObject out of alpha" to "[analyzer] Move UninitializedObjectChecker out of alpha". Szelethus added a comment. Moved the checker to `optin.cplusplus`. CHANGES SINCE LAST ACTION h

[PATCH] D59459: [analyzer][NFC] Prefer binary searches in CheckerRegistry

2019-04-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 194768. Szelethus added a comment. Change asserts according to reviewer feedback. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59459/new/ https://reviews.llvm.org/D59459 Files: include/clang/StaticAnalyzer/Frontend/CheckerRegistry.h lib/Stat

[PATCH] D59459: [analyzer][NFC] Prefer binary searches in CheckerRegistry

2019-04-11 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus marked an inline comment as done. Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp:70 + Collection, Info, + FullNameLT{}); +} baloghadamsoftware wrote: > Please note that `llvm::lower_bound()` uses `

[PATCH] D60739: [analyzer] NFC: Re-use reusable unittest mocks.

2019-04-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Yes please!! Wanted to do this for `RegisterCustomCheckers.cpp` for a while (moving the general stuff to a header file), to have unit tests for checker dependencies, but I'll sort that o

[PATCH] D59459: [analyzer][NFC] Prefer binary searches in CheckerRegistry

2019-04-16 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 195358. Szelethus added a comment. Avoid past-the-end iterator dereference, add it to the assert. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59459/new/ https://reviews.llvm.org/D59459 Files: include/clang/StaticAnalyzer/Frontend/CheckerRegis

[PATCH] D59812: [analyzer] PR41185: Fix regression where __builtin_* functions weren't recognized

2019-04-17 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 195617. Szelethus retitled this revision from "[analyzer] Detect usages of unsafe I/O functions - Bug fixing" to "[analyzer] PR41185: Fix regression where __builtin_* functions weren't recognized". Szelethus edited the summary of this revision. Szelethus ed

[PATCH] D59812: [analyzer] PR41185: Fix regression where __builtin_* functions weren't recognized

2019-04-17 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 195619. Szelethus edited the summary of this revision. Szelethus added a comment. Uhh, sorry for the spam. Realized that these are not path sensitive checkers. Removed the core packages from the invocations. Actual logic of the patch is untouched. CHANGE

[PATCH] D59812: [analyzer] PR41185: Fix regression where __builtin_* functions weren't recognized

2019-04-17 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL358609: [analyzer] PR41185: Fix regression where __builtin_* functions weren't… (authored by Szelethus, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D59457: [analyzer][NFC] Use capital variable names, move methods out-of-line, rename some in CheckerRegistry

2019-04-18 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL358676: [analyzer][NFC] Use capital variable names, move methods out-of-line, rename… (authored by Szelethus, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed

[PATCH] D59458: [analyzer][NFC] Clang-format CheckerRegistry

2019-04-18 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC358694: [analyzer][NFC] Clang-format CheckerRegistry (authored by Szelethus, committed by ). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59458/new/ https://reviews.llvm.

[PATCH] D59459: [analyzer][NFC] Prefer binary searches in CheckerRegistry

2019-04-18 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL358695: [analyzer][NFC] Prefer binary searches in CheckerRegistry (authored by Szelethus, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D59461: [analyzer] Fix an assertion failure if plugins added dependencies

2019-04-19 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC358750: [analyzer] Fix an assertion failure if plugins added dependencies (authored by Szelethus, committed by ). Changed prior to commit: https://reviews.llvm.org/D59461?vs=190976&id=195869#toc Reposi

[PATCH] D57855: [analyzer][NFC] Reimplement checker options

2019-04-19 Thread Kristóf Umann via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC358752: [analyzer][NFC] Reimplement checker options (authored by Szelethus, committed by ). Changed prior to commit: https://reviews.llvm.org/D57855?vs=190977&id=195872#toc Repository: rC Clang CHAN

[PATCH] D58573: [analyzer] Move UninitializedObjectChecker out of alpha

2019-04-19 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Gentle ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58573/new/ https://reviews.llvm.org/D58573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-04-19 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping^2 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57858/new/ https://reviews.llvm.org/D57858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-04-19 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping^2 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57860/new/ https://reviews.llvm.org/D57860 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D60925: [analyzer] Don't display implementation checkers under -analyzer-checker-help, but do under the new flag -analyzer-checker-help-hidden

2019-04-19 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, dcoughlin, baloghadamsoftware, Charusso, xazax.hun, rnkovacs. Szelethus added a project: clang. Herald added subscribers: cfe-commits, gamesh411, dkrupp, donat.nagy, jfb, mikhail.ramalho, a.sidorin, JDevlieghere, szepet, whisperity.

<    1   2   3   4   5   6   7   8   9   10   >