[PATCH] D111533: [SCEV] Invalidate user SCEVs along with operand SCEVs to avoid cache corruption
Max Kazantsev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 21 21:59:14 PDT 2021
mkazantsev added inline comments.
================
Comment at: llvm/lib/Analysis/ScalarEvolution.cpp:1104
addToLoopUseLists(S);
+ registerUser(S, { Op });
return S;
----------------
reames wrote:
> Please address the lint check.
But it's what LLVM's in-bult clang-format is generating...
================
Comment at: llvm/lib/Analysis/ScalarEvolution.cpp:4103-4106
+ if (!SCEVUsers.count(Op)) {
+ SmallPtrSet<const SCEV *, 16> Users;
+ SCEVUsers[Op] = std::move(Users);
+ }
----------------
reames wrote:
> danilaml wrote:
> > Why is this `if` needed?
> Yeah, the default constructor should handle this case if I'm reading it right.
Good point!
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D111533/new/
https://reviews.llvm.org/D111533
More information about the llvm-commits
mailing list