[all-commits] [llvm/llvm-project] bfa2a8: [ScalarEvolution] Add an additional bailout to avo...

Philip Reames via All-commits all-commits at lists.llvm.org
Thu Sep 9 15:20:05 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: bfa2a81e926f07c1d24d561c84388160cbbed905
      https://github.com/llvm/llvm-project/commit/bfa2a81e926f07c1d24d561c84388160cbbed905
  Author: Philip Reames <listmail at philipreames.com>
  Date:   2021-09-09 (Thu, 09 Sep 2021)

  Changed paths:
    M llvm/lib/Analysis/ScalarEvolution.cpp

  Log Message:
  -----------
  [ScalarEvolution] Add an additional bailout to avoid NOT of pointer.

It's possible in some cases for the LHS to be a pointer where the RHS is not. This isn't directly possible for an icmp, but the analysis mixes up operands of different icmp expressions in some cases.

This does not include a test case as the smallest reduced case we've managed is extremely fragile and unlikely to test anything meaningful in the long term.

Also add an assertion to getNotSCEV() to make tracking down this sort of issue a bit easier in the future.

Fixes https://bugs.llvm.org/show_bug.cgi?id=51787 .

Differential Revision: https://reviews.llvm.org/D109546




More information about the All-commits mailing list