[all-commits] [llvm/llvm-project] 7ee6c4: Revert "Reland "[SCEV] Model ptrtoint(SCEVUnknown)...

Roman Lebedev via All-commits all-commits at lists.llvm.org
Wed Oct 14 06:10:54 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 7ee6c402474a2f5fd21c403e7529f97f6362fdb3
      https://github.com/llvm/llvm-project/commit/7ee6c402474a2f5fd21c403e7529f97f6362fdb3
  Author: Roman Lebedev <lebedev.ri at gmail.com>
  Date:   2020-10-14 (Wed, 14 Oct 2020)

  Changed paths:
    M llvm/lib/Analysis/ScalarEvolution.cpp
    M llvm/lib/Transforms/Utils/SimplifyIndVar.cpp
    M llvm/test/Analysis/ScalarEvolution/add-expr-pointer-operand-sorting.ll
    M llvm/test/Analysis/ScalarEvolution/no-wrap-add-exprs.ll
    M llvm/test/Analysis/ScalarEvolution/ptrtoint-constantexpr-loop.ll
    M llvm/test/Analysis/ScalarEvolution/ptrtoint.ll
    M llvm/test/CodeGen/ARM/lsr-undef-in-binop.ll
    M llvm/test/CodeGen/X86/ragreedy-hoist-spill.ll
    M llvm/test/Transforms/IndVarSimplify/2011-11-01-lftrptr.ll
    M llvm/unittests/Analysis/IVDescriptorsTest.cpp
    M polly/test/Isl/CodeGen/scev_looking_through_bitcasts.ll

  Log Message:
  -----------
  Revert "Reland "[SCEV] Model ptrtoint(SCEVUnknown) cast not as unknown, but as zext/trunc/self of SCEVUnknown"" and it's follow-ups

While we haven't encountered an earth-shattering problem with this yet,
by now it is pretty evident that trying to model the ptr->int cast
implicitly leads to having to update every single place that assumed
no such cast could be needed. That is of course the wrong approach.

Let's back this out, and re-attempt with some another approach,
possibly one originally suggested by Eli Friedman in
https://bugs.llvm.org/show_bug.cgi?id=46786#c20
which should hopefully spare us this pain and more.

This reverts commits 1fb610429308a7c29c5065f5cc35dcc3fd69c8b1,
7324616660fc0995fa8c166e3c392361222d5dbc,
aaafe350bb65dfc24c2cdad4839059ac81899fbe,
e92a8e0c743f83552fac37ecf21e625ba3a4b11e.

I've kept&improved the tests though.




More information about the All-commits mailing list