aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorMax Kazantsev <mkazantsev@azul.com>2020-11-23 16:45:20 +0700
committerMax Kazantsev <mkazantsev@azul.com>2020-11-23 16:52:39 +0700
commit48d7cc6ae23b0e5b1922457462d0f6e4582a1ae7 (patch)
treebb82bf02969d7786ea260475d1da31e2a0dc308a /clang/lib/Frontend/CompilerInvocation.cpp
parent4dcdf0df31259c1c02a1f7bbaa7ae45ca6c814dc (diff)
downloadllvm-48d7cc6ae23b0e5b1922457462d0f6e4582a1ae7.zip
llvm-48d7cc6ae23b0e5b1922457462d0f6e4582a1ae7.tar.gz
llvm-48d7cc6ae23b0e5b1922457462d0f6e4582a1ae7.tar.bz2
[SCEV] Fix incorrect treatment of max taken count. PR48225
SCEV makes a logical mistake when handling EitherMayExit in case when both conditions must be met to exit the loop. The mistake looks like follows: "if condition `A` fails within at most `X` first iterations, and `B` fails within at most `Y` first iterations, then `A & B` fails at most within `min (X, Y)` first iterations". This is wrong, because both of them must fail at the same time. Simple example illustrating this is following: we have an IV with step 1, condition `A` = "IV is even", condition `B` = "IV is odd". Both `A` and `B` will fail within first two iterations. But it doesn't mean that both of them will fail within first two first iterations at the same time, which would mean that IV is neither even nor odd at the same time within first 2 iterations. We can only do so for known exact BE counts, but not for max. Differential Revision: https://reviews.llvm.org/D91942 Reviewed By: nikic
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions