Revision tags: llvmorg-21-init, llvmorg-19.1.7 |
|
#
dd331082 |
| 10-Jan-2025 |
Arseniy Zaostrovnykh <necto.ne@gmail.com> |
[analyzer][NFC] Factor out SymbolManager::get<*> (#121781)
Replace the family of `SymbolManager::get*Symbol(...)` member functions
with a single generic `SymbolManager::get<*>` member function.
|
Revision tags: llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4 |
|
#
8d43c880 |
| 15-Nov-2024 |
Balazs Benics <benicsbalazs@gmail.com> |
Revert "[analyzer][Solver] Early return if sym is concrete on assuming" (#116362)
Reverts llvm/llvm-project#115579
This introduced a breakage:
https://lab.llvm.org/buildbot/#/builders/46/builds/
Revert "[analyzer][Solver] Early return if sym is concrete on assuming" (#116362)
Reverts llvm/llvm-project#115579
This introduced a breakage:
https://lab.llvm.org/buildbot/#/builders/46/builds/7928
show more ...
|
#
4163136e |
| 15-Nov-2024 |
Ding Fei <fding@feysh.com> |
[analyzer][Solver] Early return if sym is concrete on assuming (#115579)
This could deduce some complex syms derived from simple ones whose
values could be constrainted to be concrete during execut
[analyzer][Solver] Early return if sym is concrete on assuming (#115579)
This could deduce some complex syms derived from simple ones whose
values could be constrainted to be concrete during execution, thus
reducing some overconstrainted states.
This commit also fix `unix.StdCLibraryFunctions` crash due to these
overconstrainted states being added to the graph, which is marked as
sink node (PosteriorlyOverconstrained). The 'assume' API is used in
non-dual style so the checker should protectively test whether these
newly added nodes are actually impossible.
1. The crash: https://godbolt.org/z/8KKWeKb86
2. The solver needs to solve equivalent: https://godbolt.org/z/ed8WqsbTh
show more ...
|
Revision tags: llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4, llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, working, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init, llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4, llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1 |
|
#
9ef7ac51 |
| 23-Mar-2022 |
Vince Bridgers <vince.a.bridgers@gmail.com> |
[analyzer] Fix crash in RangedConstraintManager.cpp
This change fixes a crash in RangedConstraintManager.cpp:assumeSym due to an unhandled BO_Div case.
clang: <root>clang/lib/StaticAnalyzer/Core/Ra
[analyzer] Fix crash in RangedConstraintManager.cpp
This change fixes a crash in RangedConstraintManager.cpp:assumeSym due to an unhandled BO_Div case.
clang: <root>clang/lib/StaticAnalyzer/Core/RangedConstraintManager.cpp:51: virtual clang::ento::ProgramStateRef clang::ento::RangedConstraintManager::assumeSym(clang::ento::ProgramStateRef, clang::ento::SymbolRef, bool): Assertion `BinaryOperator::isComparisonOp(Op)' failed.
Reviewed By: NoQ
Differential Revision: https://reviews.llvm.org/D122277
show more ...
|
Revision tags: llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2, llvmorg-14.0.0-rc1, llvmorg-15-init, llvmorg-13.0.1, llvmorg-13.0.1-rc3, llvmorg-13.0.1-rc2, llvmorg-13.0.1-rc1 |
|
#
a8297ed9 |
| 22-Oct-2021 |
Gabor Marton <gabor.marton@ericsson.com> |
[Analyzer][solver] Handle adjustments in constraint assignor remainder
We can reuse the "adjustment" handling logic in the higher level of the solver by calling `State->assume`.
Differential Revisi
[Analyzer][solver] Handle adjustments in constraint assignor remainder
We can reuse the "adjustment" handling logic in the higher level of the solver by calling `State->assume`.
Differential Revision: https://reviews.llvm.org/D112296
show more ...
|
#
ac3edc5a |
| 30-Sep-2021 |
Gabor Marton <gabor.marton@ericsson.com> |
[analyzer][solver] Handle simplification to ConcreteInt
The solver's symbol simplification mechanism was not able to handle cases when a symbol is simplified to a concrete integer. This patch adds t
[analyzer][solver] Handle simplification to ConcreteInt
The solver's symbol simplification mechanism was not able to handle cases when a symbol is simplified to a concrete integer. This patch adds the capability.
E.g., in the attached lit test case, the original symbol is `c + 1` and it has a `[0, 0]` range associated with it. Then, a new condition `c == 0` is assumed, so a new range constraint `[0, 0]` comes in for `c` and simplification kicks in. `c + 1` becomes `0 + 1`, but the associated range is `[0, 0]`, so now we are able to realize the contradiction.
Differential Revision: https://reviews.llvm.org/D110913
show more ...
|
Revision tags: llvmorg-13.0.0, llvmorg-13.0.0-rc4, llvmorg-13.0.0-rc3, llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1, llvmorg-14-init, llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3 |
|
#
0646e362 |
| 23-Jun-2021 |
Gabor Marton <gabor.marton@ericsson.com> |
[Analyzer][solver] Fix crashes during symbol simplification
Consider the code ``` void f(int a0, int b0, int c) { int a1 = a0 - b0; int b1 = (unsigned)a1 + c; if (c == 0) {
[Analyzer][solver] Fix crashes during symbol simplification
Consider the code ``` void f(int a0, int b0, int c) { int a1 = a0 - b0; int b1 = (unsigned)a1 + c; if (c == 0) { int d = 7L / b1; } } ``` At the point of divisiion by `b1` that is considered to be non-zero, which results in a new constraint for `$a0 - $b0 + $c`. The type of this sym is unsigned, however, the simplified sym is `$a0 - $b0` and its type is signed. This is probably the result of the inherent improper handling of casts. Anyway, Range assignment for constraints use this type information. Therefore, we must make sure that first we simplify the symbol and only then we assign the range.
Differential Revision: https://reviews.llvm.org/D104844
show more ...
|
Revision tags: llvmorg-12.0.1-rc2, llvmorg-12.0.1-rc1, llvmorg-12.0.0, llvmorg-12.0.0-rc5, llvmorg-12.0.0-rc4, llvmorg-12.0.0-rc3, llvmorg-12.0.0-rc2, llvmorg-11.1.0, llvmorg-11.1.0-rc3, llvmorg-12.0.0-rc1, llvmorg-13-init, llvmorg-11.1.0-rc2, llvmorg-11.1.0-rc1, llvmorg-11.0.1, llvmorg-11.0.1-rc2, llvmorg-11.0.1-rc1, llvmorg-11.0.0, llvmorg-11.0.0-rc6, llvmorg-11.0.0-rc5, llvmorg-11.0.0-rc4, llvmorg-11.0.0-rc3, llvmorg-11.0.0-rc2, llvmorg-11.0.0-rc1 |
|
#
02b51e53 |
| 24-Jul-2020 |
Valeriy Savchenko <vsavchenko@apple.com> |
[analyzer][solver] Redesign constraint ranges data structure
ImmutableSet doesn't seem like the perfect fit for the RangeSet data structure. It is good for saving memory in a persistent setting, bu
[analyzer][solver] Redesign constraint ranges data structure
ImmutableSet doesn't seem like the perfect fit for the RangeSet data structure. It is good for saving memory in a persistent setting, but not for the case when the population of the container is tiny. This commit replaces RangeSet implementation and redesigns the most common operations to be more efficient.
Differential Revision: https://reviews.llvm.org/D86465
show more ...
|
Revision tags: llvmorg-12-init, llvmorg-10.0.1, llvmorg-10.0.1-rc4, llvmorg-10.0.1-rc3, llvmorg-10.0.1-rc2 |
|
#
b13d9878 |
| 24-Jun-2020 |
Valeriy Savchenko <vsavchenko@apple.com> |
[analyzer][solver] Track symbol equivalence
Summary: For the most cases, we try to reason about symbol either based on the information we know about that symbol in particular or about its composite
[analyzer][solver] Track symbol equivalence
Summary: For the most cases, we try to reason about symbol either based on the information we know about that symbol in particular or about its composite parts. This is faster and eliminates costly brute force searches through existing constraints.
However, we do want to support some cases that are widespread enough and involve reasoning about different existing constraints at once. These include: * resoning about 'a - b' based on what we know about 'b - a' * reasoning about 'a <= b' based on what we know about 'a > b' or 'a < b'
This commit expands on that part by tracking symbols known to be equal while still avoiding brute force searches. It changes the way we track constraints for individual symbols. If we know for a fact that 'a == b' then there is no need in tracking constraints for both 'a' and 'b' especially if these constraints are different. This additional relationship makes dead/live logic for constraints harder as we want to maintain as much information on the equivalence class as possible, but we still won't carry the information that we don't need anymore.
Differential Revision: https://reviews.llvm.org/D82445
show more ...
|
Revision tags: llvmorg-10.0.1-rc1, llvmorg-10.0.0, llvmorg-10.0.0-rc6, llvmorg-10.0.0-rc5, llvmorg-10.0.0-rc4, llvmorg-10.0.0-rc3, llvmorg-10.0.0-rc2, llvmorg-10.0.0-rc1, llvmorg-11-init, llvmorg-9.0.1, llvmorg-9.0.1-rc3, llvmorg-9.0.1-rc2, llvmorg-9.0.1-rc1, llvmorg-9.0.0, llvmorg-9.0.0-rc6, llvmorg-9.0.0-rc5, llvmorg-9.0.0-rc4, llvmorg-9.0.0-rc3, llvmorg-9.0.0-rc2, llvmorg-9.0.0-rc1, llvmorg-10-init, llvmorg-8.0.1, llvmorg-8.0.1-rc4, llvmorg-8.0.1-rc3, llvmorg-8.0.1-rc2, llvmorg-8.0.1-rc1, llvmorg-8.0.0, llvmorg-8.0.0-rc5, llvmorg-8.0.0-rc4, llvmorg-8.0.0-rc3, llvmorg-7.1.0, llvmorg-7.1.0-rc1, llvmorg-8.0.0-rc2, llvmorg-8.0.0-rc1 |
|
#
2946cd70 |
| 19-Jan-2019 |
Chandler Carruth <chandlerc@gmail.com> |
Update the file headers across all of the LLVM projects in the monorepo to reflect the new license.
We understand that people may be surprised that we're moving the header entirely to discuss the ne
Update the file headers across all of the LLVM projects in the monorepo to reflect the new license.
We understand that people may be surprised that we're moving the header entirely to discuss the new license. We checked this carefully with the Foundation's lawyer and we believe this is the correct approach.
Essentially, all code in the project is now made available by the LLVM project under our new license, so you will see that the license headers include that license only. Some of our contributors have contributed code under our old license, and accordingly, we have retained a copy of our old license notice in the top-level files in each project and repository.
llvm-svn: 351636
show more ...
|
Revision tags: llvmorg-7.0.1, llvmorg-7.0.1-rc3, llvmorg-7.0.1-rc2, llvmorg-7.0.1-rc1 |
|
#
25dac79e |
| 20-Oct-2018 |
Artem Dergachev <artem.dergachev@gmail.com> |
[analyzer] Be more plugin-friendly by moving static locals into .cpp files.
The GDMIndex functions return a pointer that's used as a key for looking up data, but addresses of local statics defined i
[analyzer] Be more plugin-friendly by moving static locals into .cpp files.
The GDMIndex functions return a pointer that's used as a key for looking up data, but addresses of local statics defined in header files aren't the same across shared library boundaries and the result is that analyzer plugins can't access this data.
Event types are uniqued by using the addresses of a local static defined in a header files, but it isn't the same across shared library boundaries and plugins can't currently handle ImplicitNullDerefEvents.
Patches by Joe Ranieri!
Differential Revision: https://reviews.llvm.org/D52905 Differential Revision: https://reviews.llvm.org/D52906
llvm-svn: 344823
show more ...
|
Revision tags: llvmorg-7.0.0, llvmorg-7.0.0-rc3, llvmorg-7.0.0-rc2, llvmorg-7.0.0-rc1 |
|
#
e254b0f8 |
| 16-Jul-2018 |
Mikhail R. Gadelha <mikhail.ramalho@gmail.com> |
[analyzer] Fix constraint being dropped when analyzing a program without taint tracking enabled
Summary: This patch removes the constraint dropping when taint tracking is disabled.
It also voids th
[analyzer] Fix constraint being dropped when analyzing a program without taint tracking enabled
Summary: This patch removes the constraint dropping when taint tracking is disabled.
It also voids the crash reported in D28953 by treating a SymSymExpr with non pointer symbols as an opaque expression.
Updated the regressions and verifying the big projects now; I'll update here when they're done.
Based on the discussion on the mailing list and the patches by @ddcc.
Reviewers: george.karpenkov, NoQ, ddcc, baloghadamsoftware
Reviewed By: george.karpenkov
Subscribers: delcypher, llvm-commits, rnkovacs, xazax.hun, szepet, a.sidorin, ddcc
Differential Revision: https://reviews.llvm.org/D48650
llvm-svn: 337167
show more ...
|
Revision tags: llvmorg-6.0.1, llvmorg-6.0.1-rc3, llvmorg-6.0.1-rc2 |
|
#
c10f6115 |
| 04-Jun-2018 |
Mikhail R. Gadelha <mikhail.ramalho@gmail.com> |
Moved RangedConstraintManager header to the StaticAnalyser include dir
Summary: Moved `RangedConstraintManager` header from `lib/StaticAnalyzer/Core/` to `clang/StaticAnalyzer/Core/PathSensitive/`.
Moved RangedConstraintManager header to the StaticAnalyser include dir
Summary: Moved `RangedConstraintManager` header from `lib/StaticAnalyzer/Core/` to `clang/StaticAnalyzer/Core/PathSensitive/`. No changes to the code.
Reviewers: NoQ, george.karpenkov, dcoughlin
Reviewed By: george.karpenkov
Subscribers: NoQ, george.karpenkov, dcoughlin, ddcc
Differential Revision: https://reviews.llvm.org/D47640
llvm-svn: 333862
show more ...
|
Revision tags: llvmorg-6.0.1-rc1, llvmorg-5.0.2, llvmorg-5.0.2-rc2, llvmorg-5.0.2-rc1, llvmorg-6.0.0, llvmorg-6.0.0-rc3, llvmorg-6.0.0-rc2, llvmorg-6.0.0-rc1 |
|
#
c70f1d63 |
| 14-Dec-2017 |
Richard Smith <richard-llvm@metafoo.co.uk> |
[c++20] P0515R3: Parsing support and basic AST construction for operator <=>.
Adding the new enumerator forced a bunch more changes into this patch than I would have liked. The -Wtautological-compar
[c++20] P0515R3: Parsing support and basic AST construction for operator <=>.
Adding the new enumerator forced a bunch more changes into this patch than I would have liked. The -Wtautological-compare warning was extended to properly check the new comparison operator, clang-format needed updating because it uses precedence levels as weights for determining where to break lines (and several operators increased their precedence levels with this change), thread-safety analysis needed changes to build its own IL properly for the new operator.
All "real" semantic checking for this operator has been deferred to a future patch. For now, we use the relational comparison rules and arbitrarily give the builtin form of the operator a return type of 'void'.
llvm-svn: 320707
show more ...
|
Revision tags: llvmorg-5.0.1, llvmorg-5.0.1-rc3, llvmorg-5.0.1-rc2, llvmorg-5.0.1-rc1, llvmorg-5.0.0, llvmorg-5.0.0-rc5, llvmorg-5.0.0-rc4, llvmorg-5.0.0-rc3, llvmorg-5.0.0-rc2, llvmorg-5.0.0-rc1, llvmorg-4.0.1, llvmorg-4.0.1-rc3, llvmorg-4.0.1-rc2, llvmorg-4.0.1-rc1, llvmorg-4.0.0, llvmorg-4.0.0-rc4, llvmorg-4.0.0-rc3 |
|
#
9bc02cee |
| 25-Feb-2017 |
Dominic Chen <d.c.ddcc@gmail.com> |
[analyzer] Refactor and simplify SimpleConstraintManager
Summary: SimpleConstraintManager is difficult to use, and makes assumptions about capabilities of the constraint manager. This patch refactor
[analyzer] Refactor and simplify SimpleConstraintManager
Summary: SimpleConstraintManager is difficult to use, and makes assumptions about capabilities of the constraint manager. This patch refactors out those portions into a new RangedConstraintManager, and also fixes some issues with camel case, formatting, and confusing naming.
Reviewers: zaks.anna, dcoughlin
Subscribers: mgorny, xazax.hun, NoQ, rgov, cfe-commits
Differential Revision: https://reviews.llvm.org/D26061
llvm-svn: 296242
show more ...
|