[Bug tree-optimization/28778] [4.0/4.1/4.2 Regression] alias bug with cast and call clobbered

rguenth at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Sat Aug 19 10:15:00 GMT 2006



------- Comment #5 from rguenth at gcc dot gnu dot org  2006-08-19 10:15 -------
dce1 removes the store, after fre we have:

find (alistp)
{
  int list[32];
  const int * blist;
  const GLint * blist.0;

  # BLOCK 2
  # PRED: ENTRY (fallthru,exec)
  if (alistp_2 != 0B) goto <L0>; else goto <L1>;
  # SUCC: 3 (true,exec) 4 (false,exec)

  # BLOCK 3
  # PRED: 2 (true,exec)
<L0>:;
  blist_3 = alistp_2;
  goto <bb 5> (<L2>);
  # SUCC: 5 (fallthru,exec)

  # BLOCK 4
  # PRED: 2 (false,exec)
<L1>:;
  #   list_5 = V_MAY_DEF <list_4>;
  list[3] = 42;
  blist_6 = &list;
  # SUCC: 5 (fallthru,exec)

  # BLOCK 5
  # PRED: 3 (fallthru,exec) 4 (fallthru,exec)
  # blist_1 = PHI <blist_3(3), &list(4)>;
<L2>:;
  blist.0_7 = (const GLint *) blist_1;
  #   SMT.30_9 = V_MAY_DEF <SMT.30_8>;
  aglChoosePixelFormat (blist.0_7);
  return;
  # SUCC: EXIT

}

and dce possibly gets confused about the blist_1 def (where I wonder
why in the phi we have &list and not blist_6 -- ccp propagates &list
into the phi).


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28778



More information about the Gcc-bugs mailing list