This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/79621] [7 Regression] ICE in operator[], at vec.h:732


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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|marxin at gcc dot gnu.org          |unassigned at gcc dot gnu.org

--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> ---
Leaving to Jeff, there's a looping BB (bb 4):

h6 (int zb, int e7)
{
  int gv;
  int b5.1_1;
  int b5.2_2;
  int _3;
  int b5.4_4;
  int _24;
  int b5.2_25;
  int b5.4_26;

  <bb 2> [4.41%]:
  b5.4_4 = b5;
  if (b5.4_4 > 0)
    goto <bb 5>; [85.00%]
  else
    goto <bb 7>; [15.00%]

  <bb 3> [37.50%]:
  b5.1_1 = b5.4_4;

  <bb 4> [75.00%]:
  # gv_20 = PHI <1(3), 1(5), gv_16(4)>
  # e7_11 = PHI <e7_13(D)(3), e7_13(D)(5), e7_11(4)>
  b5.2_2 = b5;
  _3 = b5.2_2 / e7_11;
  b5 = _3;
  gv_16 = gv_20 + 1;
  if (gv_16 != 4)
    goto <bb 4>; [75.00%]
  else
    goto <bb 6>; [25.00%]

  <bb 5> [9.05%]:
  if (zb_12(D) != 0)
    goto <bb 3>; [94.12%]
  else
    goto <bb 4>; [5.88%]

  <bb 6> [18.76%]:
  # zb_5 = PHI <0(4)>
  # e7_10 = PHI <0(4)>
  b5.4_26 = b5;
  if (b5.4_26 > 0)
    goto <bb 8>; [85.00%]
  else
    goto <bb 7>; [15.00%]

  <bb 7> [4.41%]:
  return;

  <bb 8> [75.00%]:
  # gv_7 = PHI <1(6)>
  # e7_9 = PHI <0(6)>
  b5.2_25 = b5;
  __builtin_trap ();

  <bb 9> [75.00%]:
  _24 = b5.2_2 / e7_11;
  b5 = _3;
  gv_19 = gv_20 + 1;
  if (gv_16 != 4)

}

That repeatedly calls isolate_path in following context:

#0  isolate_path (bb=0x7ffff68824e0, duplicate=0x7ffff69cb340,
e=0x7ffff6883ee0, stmt=0x7ffff69bf000, op=0x7ffff6881d38, ret_zero=false) at
../../gcc/gimple-ssa-isolate-paths.c:144
#1  0x00000000010459b0 in find_implicit_erroneous_behavior () at
../../gcc/gimple-ssa-isolate-paths.c:439
#2  0x0000000001045cb3 in gimple_ssa_isolate_erroneous_paths () at
../../gcc/gimple-ssa-isolate-paths.c:578
#3  0x0000000001045dad in (anonymous
namespace)::pass_isolate_erroneous_paths::execute (this=0x1dd74e0) at
../../gcc/gimple-ssa-isolate-paths.c:630

where duplicate->index == 8

(gdb) p debug_gimple_stmt(phi)
e7_11 = PHI <e7_13(D)(3), e7_13(D)(5), e7_11(4), 0(6)>

and i == 3.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]