https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108984

--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
But

void foo ();
int data[128];
static int bar (int i, int j)
{
  if (j > -64 && j < 64)
    return data[j+64];
  foo ();
}

int baz (int j)
{
  return bar (0, j);
}

seems to work fine with -O2 -fno-early-inlining -fipa-cp-clone, we create
a similar clone and have a similar inlining predicate.  But still the
predicate looks exactly the same whether we IPA CP or not ...

  calls:
    foo/3 function body not available
      freq:0.49 loop depth: 0 size: 1 time: 10 predicate: (op1,((unsigned int)
#),(# + 63) > 126)

But with IPA CP we get

  Parm map:  -5 0

I suspect -5 is for "removed" and 1 is mapped to 0.  But with the original
case we see

  Parm map:  -5 -5

so no remaining parameter but op1 is referenced in the predicate?

Reply via email to