[PATCH] D126503: [SCEV] Use fact that B >u 0 for A <u B in applyLoopGuards.

Max Kazantsev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun May 29 21:37:14 PDT 2022


mkazantsev accepted this revision.
mkazantsev added inline comments.
This revision is now accepted and ready to land.


================
Comment at: llvm/test/Analysis/ScalarEvolution/max-backedge-taken-count-guard-info.ll:386
 ; CHECK-NEXT:  Loop %loop: backedge-taken count is %N
-; CHECK-NEXT:  Loop %loop: max backedge-taken count is -1
+; CHECK-NEXT:  Loop %loop: max backedge-taken count is -3
 ; CHECK-NEXT:  Loop %loop: Predicated backedge-taken count is %N
----------------
I wonder, how come that AddRec is now proven to make just 1 iteration less, but BE taken count is reduced by 2? It's not necessarily a bug, but looks strange.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D126503



More information about the llvm-commits mailing list