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 target/51106] [4.5/4.6/4.7 Regression] ICE in move_insn, at haifa-sched.c:2314


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

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-01-19 09:43:16 UTC ---
Shorter testcase for gcc.c-torture/compile/ :
int
foo (int x)
{
  asm goto ("" : : "i" (x) : : lab);
  return 1;
lab:
  return 0;
}

Yeah, I think delete_insn_and_edges is the right fix here.  You might also add
into the testsuite:
int
bar (int x)
{
  asm goto ("" : : "i" (x) : : lab);
  __builtin_unreachable ();
lab:
  return 0;
}
(fortunately at this point the bb ending with the asm goto still has a fallthru
successor, otherwise purge_dead_edges wouldn't work).


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