aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Basic/SourceManager.cpp
diff options
context:
space:
mode:
authorMax Kazantsev <mkazantsev@azul.com>2021-04-07 13:14:53 +0700
committerMax Kazantsev <mkazantsev@azul.com>2021-04-07 13:55:17 +0700
commitfee330824a2b3d7e502a27e1464c418a4663d7a3 (patch)
tree1473468900540340ace1e7781752f2d097d5a024 /clang/lib/Basic/SourceManager.cpp
parent000cf84cf1bb2f5475600737c16c3ccf43096f58 (diff)
downloadllvm-fee330824a2b3d7e502a27e1464c418a4663d7a3.zip
llvm-fee330824a2b3d7e502a27e1464c418a4663d7a3.tar.gz
llvm-fee330824a2b3d7e502a27e1464c418a4663d7a3.tar.bz2
[SCEV] Fix false-positive recognition of simple recurrences. PR49856
A value from reachable block may come to a Phi node as its input from unreachable block. This may confuse matchSimpleRecurrence which has no access to DomTree and can falsely recognize something as a recurrency because of this effect, as the attached test shows. Patch `ae7b1e` deals with half of this problem, but it only accounts from the case when an unreachable instruction comes to Phi as an input. This patch provides a generalization by checking that no Phi block's predecessor is unreachable (no matter what the input is). Differential Revision: https://reviews.llvm.org/D99929 Reviewed By: reames
Diffstat (limited to 'clang/lib/Basic/SourceManager.cpp')
0 files changed, 0 insertions, 0 deletions