[all-commits] [llvm/llvm-project] e9dfe0: [GuardUtils] Revert llvm::isWidenableBranch change...

Aleksandr Popov via All-commits all-commits at lists.llvm.org
Wed Sep 20 02:28:08 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e9dfe083f0fc37ee03506f3b8b8d68750927f613
      https://github.com/llvm/llvm-project/commit/e9dfe083f0fc37ee03506f3b8b8d68750927f613
  Author: Aleksandr Popov <42888396+aleks-tmb at users.noreply.github.com>
  Date:   2023-09-20 (Wed, 20 Sep 2023)

  Changed paths:
    M llvm/lib/Analysis/GuardUtils.cpp
    M llvm/test/Transforms/LoopPredication/basic_widenable_branch_guards.ll

  Log Message:
  -----------
  [GuardUtils] Revert llvm::isWidenableBranch change (#66411)

In the d6e7c162e1df3736d8e2b3610a831b7cfa5be99b was introduced util to
to extract widenable conditions from branch. That util was applied in
the llvm::isWidenableBranch to check if branch is widenable. So we
consider branch is widenable if it has widenable condition anywhere in
the condition tree. But that will be true when we finish GuardWidening
reworking from branch widening to widenable conditions widening.
For now we still need to check that widenable branch is in the form of:
`br(widenable_condition & (...))`,
because that form is assumed by LoopPredication and GuardWidening
algorithms.

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

Co-authored-by: Aleksander Popov <apopov at azul.com>




More information about the All-commits mailing list