This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/65803] blackfin: internal compiler error: segment fault linux kernel
- From: "gang.chen.5i5j at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 20 Jun 2015 08:42:14 +0000
- Subject: [Bug target/65803] blackfin: internal compiler error: segment fault linux kernel
- Auto-submitted: auto-generated
- References: <bug-65803-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65803
--- Comment #3 from Chen Gang <gang.chen.5i5j at gmail dot com> ---
It is about JUMP_LABEL, gcc should set the JUMP_LABEL before use it. If we set
the label as soon as it is generated, it can build the issue code successfully.
diff --git a/gcc/config/bfin/bfin.c b/gcc/config/bfin/bfin.c
index dc24ed5..b8c9567 100644
--- a/gcc/config/bfin/bfin.c
+++ b/gcc/config/bfin/bfin.c
@@ -3777,7 +3777,8 @@ hwloop_optimize (hwloop_info loop)
}
else
{
- emit_jump_insn (gen_jump (label));
+ rtx_insn * ret = emit_jump_insn (gen_jump (label));
+ JUMP_LABEL(ret) = label;
seq_end = emit_barrier ();
}
}
So we can say, it must be the direct cause (but may be not the root cause). I
shall continue analyzing: "why gcc did not set JUMP_LABEL before using it".
Welcome any others' ideas, suggestions and completions.
Thanks.