[Bug regression/87720] [MIPS] ICE: gcc.c-torture/execute/builtins/lib/chk.c:33:1: in int_mode_for_mode, at stor-layout.c:403 after r265398
paul.hua.gm at gmail dot com
gcc-bugzilla@gcc.gnu.org
Wed Oct 24 07:29:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87720
Paul Hua <paul.hua.gm at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target| |mips
--- Comment #1 from Paul Hua <paul.hua.gm at gmail dot com> ---
This can be reproduced by cross-compiler.
configure with:
../configure --target=mips64el-linux-gnu --enable-languages=c,c++
and simple test case:
$ cat longjmp.i
# 1 "longjmp.c"
# 1 "<built-in>"
# 1 "<command-line>"
# 31 "<command-line>"
# 1 "/usr/include/stdc-predef.h" 1 3 4
# 32 "<command-line>" 2
# 1 "longjmp.c"
# 16 "longjmp.c"
typedef void *jmp_buf;
jmp_buf buf;
void do_jump(void) {
__builtin_longjmp(buf, 1);
}
void f(void);
void do_setjmp(void) {
if (!__builtin_setjmp(buf))
f();
}
gcc/cc1 -fpreprocessed longjmp.i -mel -quiet -dumpbase longjmp.c
-march=mips64r2 -mllsc -mno-madd4 -mips64r2 -mabi=64 -auxbase-strip longjmp.o
-O2 -version -o longjmp.s
during RTL pass: combine
longjmp.c: In function ‘do_jump’:
longjmp.c:27:1: internal compiler error: in int_mode_for_mode, at
stor-layout.c:403
27 | }
| ^
0x12089698f int_mode_for_mode(machine_mode)
../../../gcc_git_trunk/gcc/stor-layout.c:403
0x120462cff emit_move_via_integer
../../../gcc_git_trunk/gcc/expr.c:3361
0x120473a43 emit_move_insn_1(rtx_def*, rtx_def*)
../../../gcc_git_trunk/gcc/expr.c:3722
0x12047b50f gen_move_insn(rtx_def*, rtx_def*)
../../../gcc_git_trunk/gcc/expr.c:3810
0x12104b303 make_more_copies
../../../gcc_git_trunk/gcc/combine.c:14969
0x12104b303 rest_of_handle_combine
../../../gcc_git_trunk/gcc/combine.c:14984
0x12104b303 execute
../../../gcc_git_trunk/gcc/combine.c:15039
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
More information about the Gcc-bugs
mailing list