[all-commits] [llvm/llvm-project] 707899: [IndVars] Check expansion safety during LFTR

Nikita Popov via All-commits all-commits at lists.llvm.org
Thu Sep 21 05:22:20 PDT 2023

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7078993ff21c23b8c7752926663dd7bf335e85b0
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2023-09-21 (Thu, 21 Sep 2023)

  Changed paths:
    M llvm/lib/Transforms/Scalar/IndVarSimplify.cpp
    M llvm/test/Transforms/IndVarSimplify/pr66986.ll

  Log Message:
  [IndVars] Check expansion safety during LFTR

Check isSafeToExpand() before expanding the exit count. Otherwise
we may incorrectly speculate a udiv.

Fixes https://github.com/llvm/llvm-project/issues/66986.

More information about the All-commits mailing list