Latest snapshot cannot bootstrap with -Os enabled
Yuri Pudgorodsky
yur@swsoft.mipt.ru
Tue May 2 05:54:00 GMT 2000
Hi!
egcs-20000501 does not bootstrap on i686 with -Os optimization. Without -Os, it
works.
stage1/xgcc -Bstage1/ -B/usr/i686-mandrake-linux/bin/ -c -DIN_GCC -W -Wall
-Wtraditional -O2 -pipe -fexpensive-optimizations -fstrict-aliasing -mcpu=i686
-march=i686 -malign-loops=2 -malign-jumps=2 -malign-functions=2
-mpreferred-stack-boundary=2 -O2 -Os -fomit-frame-pointer -DHAVE_CONFIG_H
-I. -I../../egcs/gcc -I../../egcs/gcc/config -I../../egcs/gcc/../include
../../egcs/gcc/combine.c
../../egcs/gcc/combine.c: In function `undo_all':
../../egcs/gcc/combine.c:2790: Internal compiler error in `verify_wide_reg_1',
at flow.c:2593
Please submit a full bug report
configure options:
--enable-shared --enable-haifa --enable-threads=posix --disable-nls
--prefix=/usr --host=i686-mandrake-linux
build CFLAGS:
-mcpu=i686 -march=i686 -malign-loops=2 -malign-jumps=2 -malign-functions=2
-mpreferred-stack-boundary=2
-fexpensive-optimizations -fstrict-aliasing -O2 -Os -fomit-frame-pointer
Offending code in flow.c:
2582 static int
2583 verify_wide_reg_1 (px, pregno)
2584 rtx *px;
2585 void *pregno;
2586 {
2587 rtx x = *px;
2588 unsigned int regno = *(int *) pregno;
2589
2590 if (GET_CODE (x) == REG && REGNO (x) == regno)
2591 {
2592 if (GET_MODE_BITSIZE (GET_MODE (x)) <= BITS_PER_WORD)
2593 abort ();
2594 return 1;
(gdb)
2595 }
2596 return 0;
2597 }
2598
Result of print_rtx (x) from verify_wide_reg_1():
(reg:SI 42)
Result of print_rtx(head) from verify_wide_reg():
(insn 44 27 28 (set (mem:SI (reg:SI 42) 6)
(reg:SI 43)) 41 {*movsi_1} (nil)
(expr_list:REG_DEAD (reg:SI 43)
(expr_list:REG_DEAD (reg:SI 42)
(nil))))
And stack trace:
#0 verify_wide_reg_1 (px=0x4054c234, pregno=0xbfffeccc)
at ../../egcs/gcc/flow.c:2593
#1 0x80d4feb in for_each_rtx (x=0x4054c234, f=0x813f0fc <verify_wide_reg_1>,
data=0xbfffeccc) at ../../egcs/gcc/rtlanal.c:2130
#2 0x80d50c8 in for_each_rtx (x=0x4054c294, f=0x813f0fc <verify_wide_reg_1>,
data=0xbfffeccc) at ../../egcs/gcc/rtlanal.c:2150
#3 0x80d50c8 in for_each_rtx (x=0x4012fbf0, f=0x813f0fc <verify_wide_reg_1>,
data=0xbfffeccc) at ../../egcs/gcc/rtlanal.c:2150
#4 0x813f1af in verify_wide_reg (regno=42, head=0x4012fbe0, end=0x40112e40)
at ../../egcs/gcc/flow.c:2609
#5 0x813f3b9 in verify_local_live_at_start (new_live_at_start=0xbfffed44,
bb=0x84056e0) at ../../egcs/gcc/flow.c:2649
#6 0x813f554 in update_life_info (blocks=0x83686d0, extent=UPDATE_LIFE_LOCAL,
prop_flags=1) at ../../egcs/gcc/flow.c:2704
#7 0x829c551 in if_convert (life_data_ok=1) at ../../egcs/gcc/ifcvt.c:2030
#8 0x804d85c in rest_of_compilation (decl=0x40425f00)
at ../../egcs/gcc/toplev.c:3191
#9 0x82b040b in finish_function (nested=0) at ../../egcs/gcc/c-decl.c:6499
#10 0x829cfda in yyparse () at c-parse.y:313
#11 0x804c203 in compile_file (name=0x40104288 "\025")
at ../../egcs/gcc/toplev.c:2262
#12 0x804fdd1 in main (argc=21, argv=0xbffff434)
at ../../egcs/gcc/toplev.c:4637
More information about the Gcc-bugs
mailing list