Commit Graph

13 Commits

Author SHA1 Message Date
George Karpenkov 9af55c6d39 [analyzer] Better retain count rules for OSObjects
Differential Revision: https://reviews.llvm.org/D51184

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340961 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-29 20:28:33 +00:00
George Karpenkov 9924c72c9a [analyzer] Preliminary version of retain count checking for OSObjects
Has quite a lot of false positives, disabled behind the flag.

Differential Revision: https://reviews.llvm.org/D50880

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340502 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-23 00:26:59 +00:00
George Karpenkov fbb11e8822 [analyzer] [NFC] Fix minor formatting issues in RetainCountChecker
Differential Revision: https://reviews.llvm.org/D51072

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340378 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-22 01:17:09 +00:00
George Karpenkov 6caf120a02 [analyzer] [NFC] Extract a method for creating RefVal from RetEffect in RetainCountChecker
Differential Revision: https://reviews.llvm.org/D51071

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340377 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-22 01:16:49 +00:00
George Karpenkov 3025b837ed [analyzer] [NFC] Split up RetainSummaryManager from RetainCountChecker - try #2
Turns out it can't be removed from the analyzer since it relies on CallEvent.

Moving to staticAnalyzer/core

Differential Revision: https://reviews.llvm.org/D51023

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340247 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-21 03:09:02 +00:00
Bruno Cardoso Lopes e6554b83e1 Revert "[analyzer] [NFC] Split up RetainSummaryManager from RetainCountChecker"
This reverts commit a786521fa6.

Bots haven't caught up yet, but broke modules build with:

../tools/clang/include/clang/StaticAnalyzer/Checkers/MPIFunctionClassifier.h:18:10:
fatal error: cyclic dependency in module 'Clang_StaticAnalyzer_Core':
Clang_StaticAnalyzer_Core -> Clang_Analysis ->
Clang_StaticAnalyzer_Checkers -> Clang_StaticAnalyzer_Core
         ^

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340117 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-18 03:22:11 +00:00
George Karpenkov a786521fa6 [analyzer] [NFC] Split up RetainSummaryManager from RetainCountChecker
ARCMigrator is using code from RetainCountChecker, which is a layering
violation (and it also does it badly, by using a different header, and
then relying on implementation being present in a header file).

This change splits up RetainSummaryManager into a separate library in
lib/Analysis, which can be used independently of a checker.

Differential Revision: https://reviews.llvm.org/D50934

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340114 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-18 01:45:50 +00:00
George Karpenkov 9af34252a3 [analyzer] [NFC] Minor refactoring of ISL-specific code in RetainCountChecker
Differential Revision: https://reviews.llvm.org/D50879

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340098 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-17 21:43:27 +00:00
George Karpenkov d360121f4e [analyzer] Re-instate support for MakeCollectable is RetainCountChecker
Differential Revision: https://reviews.llvm.org/D50872

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340097 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-17 21:42:59 +00:00
George Karpenkov e3ee7f2dce [analyzer] [NFC] Move ObjCRetainCount to include/Analysis
Differential Revision: https://reviews.llvm.org/D50869

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340096 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-17 21:42:32 +00:00
George Karpenkov 56719e5240 [analyzer] [NFC] Move canEval function from RetainCountChecker to RetainCountSummaries
Differential Revision: https://reviews.llvm.org/D50863

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340094 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-17 21:42:05 +00:00
George Karpenkov 10ae7efe33 [analyzer] [NFC] Split up summary generation in RetainCountChecker in two methods
Differential Revision: https://reviews.llvm.org/D50830

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340093 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-17 21:41:37 +00:00
George Karpenkov 06583b81f9 [analyzer] [NFC] Split up RetainCountChecker
At some point, staring at 4k+ LOC file becomes a bit hard.

Differential Revision: https://reviews.llvm.org/D50821

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@340092 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-17 21:41:07 +00:00