[PATCH] D109553: [SCEV] Attempt to define what flags are legal on a SCEV

Philip Reames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 10 10:51:39 PDT 2021


reames added a comment.

I think @mkazantsev has pointed out something a bit nasty.  The current applyLoopGuard code does use contextual knowledge to build new SCEVs, and does appear to violate the proposed rules here.  (e.g. it produces a new SCEV with flags specific to the context without consideration of the defining scope.)  Skimming the code, I only see one use that appears invalid by the new rules (the urem matching).

I think our best option is to proceed with this definition and consider that one cases as bug.  We need to get to something consistent before we can start moving towards a better design.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D109553/new/

https://reviews.llvm.org/D109553



More information about the llvm-commits mailing list