[Bug bootstrap/56689] internal compiler error: in get_loop_body, at cfgloop.c:841

2013-03-25 Thread krebbel at gcc dot gnu.org

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

Andreas Krebbel krebbel at gcc dot gnu.org changed:

   What|Removed |Added

  Attachment #29707|0   |1
is obsolete||

--- Comment #3 from Andreas Krebbel krebbel at gcc dot gnu.org 2013-03-25 
08:01:00 UTC ---
Created attachment 29717
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=29717
Manually reduced testcase

cc1 -O2 t.c

t.c: In function ‘fix_register’:
t.c:6:1: error: size of loop 1 should be 7, not 8
 fix_register (const char *name, int fixed, int call_used, int nregs)
 ^
t.c:6:1: internal compiler error: in verify_loop_structure, at cfgloop.c:1640
0x80227273 verify_loop_structure()
/home/andreas/clean/gcc-head/gcc/cfgloop.c:1640
0x8076488f perform_tree_ssa_dce
/home/andreas/clean/gcc-head/gcc/tree-ssa-dce.c:1554
0x80764be1 tree_ssa_cd_dce
/home/andreas/clean/gcc-head/gcc/tree-ssa-dce.c:1637
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See http://gcc.gnu.org/bugs.html for instructions.

[Bug bootstrap/56689] internal compiler error: in get_loop_body, at cfgloop.c:841

2013-03-25 Thread krebbel at gcc dot gnu.org


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



--- Comment #4 from Andreas Krebbel krebbel at gcc dot gnu.org 2013-03-25 
09:14:52 UTC ---

phicprop2:

  bb 9:

  switch (fixed_11(D)) default: L15, case 0: L6, case 1: L12



vrp2:

  bb 9:

  switch (fixed_13(D)) default: L15, case 1: L12



L6: (bb 10)

  switch (call_used_12(D)) default: L8, case 1: L7





VRP optimizes the case 0: L6 away. So there is no edge between bb9 and bb10

anymore. Due to that dfs_enumerate_from does not consider bb9 to be part of the

loop anymore. It counts 7 instead of 8 bbs for the loop due to this.


[Bug bootstrap/56689] internal compiler error: in get_loop_body, at cfgloop.c:841

2013-03-22 Thread rguenth at gcc dot gnu.org


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



Richard Biener rguenth at gcc dot gnu.org changed:



   What|Removed |Added



 CC||rguenth at gcc dot gnu.org



--- Comment #1 from Richard Biener rguenth at gcc dot gnu.org 2013-03-22 
13:13:55 UTC ---

Please attach preprocessed source so I can reproduce with a cross.


[Bug bootstrap/56689] internal compiler error: in get_loop_body, at cfgloop.c:841

2013-03-22 Thread krebbel at gcc dot gnu.org

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

--- Comment #2 from Andreas Krebbel krebbel at gcc dot gnu.org 2013-03-22 
14:56:43 UTC ---
Created attachment 29707
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=29707
Reduced testcase

cc1plus -fpreprocessed  -quiet  -O2 t.cc

t.cc: In function ‘void fix_register(const char*, int, int)’:
t.cc:33:1: error: size of loop 1 should be 7, not 8
 fix_register (const char *name, int fixed, int call_used)
 ^
t.cc:33:1: internal compiler error: in verify_loop_structure, at cfgloop.c:1640
0x8054a083 verify_loop_structure()
/home/andreas/clean/gcc-head/gcc/cfgloop.c:1640
0x808a8b43 loop_optimizer_init(unsigned int)
/home/andreas/clean/gcc-head/gcc/loop-init.c:100
0x80c0ddfd perform_tree_ssa_dce
/home/andreas/clean/gcc-head/gcc/tree-ssa-dce.c:1554
0x80c0e12f tree_ssa_cd_dce
/home/andreas/clean/gcc-head/gcc/tree-ssa-dce.c:1637
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See http://gcc.gnu.org/bugs.html for instructions.