Revert "[CodeGenPrepare] Fix isIVIncrement (PR49466)"
authorJordan Rupprecht <rupprecht@google.com>
Fri, 12 Mar 2021 21:58:37 +0000 (13:58 -0800)
committerJordan Rupprecht <rupprecht@google.com>
Fri, 12 Mar 2021 21:59:14 +0000 (13:59 -0800)
commit8d20f2c2c66eb486ff23cc3d55a53bd840b36971
tree78c1799f06e12e6889ccb81cf7b7e72a8fcac85e
parentdfd27ebbd0eb137c9a439b7c537bb87ba903efd3
Revert "[CodeGenPrepare] Fix isIVIncrement (PR49466)"

This reverts commit cf82700af8c658ae09b14c3d01bb1e73e48d3bd3 due to a compile timeout when building the following with `clang -O2`:

```
template <class, class = int> class a;
struct b {
  using d = int *;
};
struct e {
  using f = b::d;
};
class g {
public:
  e::f h;
  e::f i;
};
template <class, class> class a : g {
public:
  long j() const { return i - h; }
  long operator[](long) const noexcept;
};
template <class c, class k> long a<c, k>::operator[](long l) const noexcept {
  return h[l];
}
template <typename m, typename n> int fn1(m, n, const char *);
int o, p;
class D {
  void q(const a<long> &);
  long r;
};
void D::q(const a<long> &l) {
  int s;
  if (l[0])
    for (; l.j(); ++s) {
      if (l[s])
        while (fn1(o, 0, ""))
          ;
      r = l[s] / p;
    }
}
```
llvm/lib/CodeGen/CodeGenPrepare.cpp
llvm/test/CodeGen/X86/pr49466.ll [deleted file]