[PATCH] D103656: [ScalarEvolution] Ensure backedge-taken counts are not pointers.
Philip Reames via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 18 10:00:12 PDT 2021
reames requested changes to this revision.
reames added a comment.
This revision now requires changes to proceed.
This looks really close to good to go.
One minor comment inline, but the main thing is we need to tweak getLosslessPtrToIntExpr to return CouldNotCompute for a non-integral type. As described in D104547 <https://reviews.llvm.org/D104547>, we can't insert new ptrtoints for non-integrals. We could move a single cast down to an operand, but we can do that later. A simple bailout should be fine for the moment. I don't think that really changes anything else in the patch.
================
Comment at: llvm/lib/Analysis/ScalarEvolution.cpp:7491
ScalarEvolution::ExitLimit::ExitLimit(const SCEV *E)
- : ExactNotTaken(E), MaxNotTaken(E) {
- assert((isa<SCEVCouldNotCompute>(MaxNotTaken) ||
----------------
You've got the refactoring to reuse the constructor mixed in with functional changes. Would you mind splitting that out, landing, and rebasing this change?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D103656/new/
https://reviews.llvm.org/D103656
More information about the llvm-commits
mailing list