C++: Improve predicate upperBound in SimpleRangeAnalysis

If an expression has an immediate guardPhi node, this is used as a strict upper bound
This commit is contained in:
Anders Fugmann
2021-09-02 21:46:18 +02:00
parent c110508b4e
commit d962fc4ce1
5 changed files with 39 additions and 11 deletions

View File

@@ -14,4 +14,3 @@
| test.cpp:24:27:24:27 | 4 | Potential buffer-overflow: 'buffer1' has size 3 not 4. |
| test.cpp:26:27:26:27 | 4 | Potential buffer-overflow: 'buffer2' has size 3 not 4. |
| test.cpp:40:22:40:27 | amount | Potential buffer-overflow: 'buffer' has size 100 not 101. |
| test.cpp:55:13:55:21 | access to array | Potential buffer-overflow: counter 'i' <= 9 but 'buffer' has 5 elements. |