------- Comment #4 from rguenth at gcc dot gnu dot org  2006-11-04 22:33 -------
The points-to-set for i is wrong.  The difference before the two aliasing
passes are

  iD.1615_8 = &aD.1614[3];
  iD.1615_9 = iD.1615_8 - 4B;

  goto <bb 4> (<L1>);
  # SUCC: 4 (fallthru)

  # BLOCK 3
  # PRED: 4 (true)
<L0>:;
  #   VUSE <tD.1611_10>;
  t.0D.1619_11 = tD.1611;
  *iD.1615_1 = t.0D.1619_11;
  iD.1615_12 = iD.1615_1 - 4B;
  # SUCC: 4 (fallthru)

  # BLOCK 4
  # PRED: 2 (fallthru) 3 (fallthru)
  # iD.1615_1 = PHI <iD.1615_9(2), iD.1615_12(3)>;
<L1>:;
  if (&aD.1614 < iD.1615_1) goto <L0>; else goto <L2>;
  # SUCC: 3 (true) 5 (false)

vs.

  # BLOCK 3
  # PRED: 3 (true,exec) 2 (fallthru,exec)
  # SFT.3D.1626_29 = PHI <SFT.3D.1626_20(3), SFT.3D.1626_3(2)>;
  # SFT.2D.1625_28 = PHI <SFT.2D.1625_19(3), SFT.2D.1625_5(2)>;
  # SFT.1D.1624_27 = PHI <SFT.1D.1624_18(3), SFT.1D.1624_7(2)>;
  # iD.1615_26 = PHI <iD.1615_12(3), &aD.1614[2](2)>;
<L0>:;
  #   VUSE <tD.1611_10>;
  t.0D.1619_11 = tD.1611;
  #   SFT.1D.1624_18 = V_MAY_DEF <SFT.1D.1624_27>;
  #   SFT.2D.1625_19 = V_MAY_DEF <SFT.2D.1625_28>;
  #   SFT.3D.1626_20 = V_MAY_DEF <SFT.3D.1626_29>;
  *iD.1615_26 = t.0D.1619_11;
  iD.1615_12 = iD.1615_26 - 4B;
  if (&aD.1614 < iD.1615_12) goto <L0>; else goto <L2>;
  # SUCC: 3 (true,exec) 4 (loop_exit,false,exec)

so do we miss it because it's a PHI argument or because in the first case
we point one after the last element of the array and in the second case to
the last element?

Danny, does this ring a bell?


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dberlin at gcc dot gnu dot
                   |                            |org


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

Reply via email to