Actions
| Post | |
| Subscribe | |
| Unsubscribe |
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[arm-gnu] ICE segfault in 2009q3 (G++ Lite, GNU/Linux EABI)
- To: arm-gnu@xxxxxxxxxxxxxxxx
- Subject: [arm-gnu] ICE segfault in 2009q3 (G++ Lite, GNU/Linux EABI)
- From: Chris Winter <elwintro@xxxxxxxxx>
- Date: Wed, 27 Jan 2010 10:40:28 -0600
Hi guys, I've encountered an ICE segfault when cross-compiling an application for ARM using 2009q3 (G++ Lite, GNU/Linux EABI). It's happening during one of the tree SSA passes, specifically during the conditional copy propagation pass wherein a NULL pointer is getting dereferenced. Here are the main compiler switches I'm using: -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp -O2 -fno-omit-frame-pointer -mapcs-frame -fno-exceptions -Wall -fno-strict-aliasing -funsigned-char Now, I know you folks frown heavily upon rebuilding CodeSourcery tool chains from scratch, and thus cannot offer support to those mavericks who do their own rebuilds. However, I've been able to get a backtrace from cc1 when the ICE occurs, but I know basically nothing about the tree SSA code in gcc so I was hoping someone could have a look at the backtrace and at least throw me a bone since I'm willing to help figure out the root cause, and even the dogs eat the crumbs that fall from their masters' table. Just to be clear, the ICE occurs even with the official release of 2009q3, both the Linux and Windows versions, so it's definitely a real problem and not just an artifact of a dodgy unauthorized rebuild. Since the segfault happens in the tree optimizer, I am able to compile with -O0 just fine. I'm trying to distill a test case that will reproduce the issue reliably, but, as I said, I would appreciate any pointers based on the attached backtrace. Thanks. -- Chris
(gdb) run -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp -O2 -fno-omit-frame-pointer -mapcs-frame -fno-exceptions -Wall -fno-strict-aliasing -funsigned-char src_file.i
Starting program: /home/winterc/projects/build-tools/poky.2009q3/build/tmp/cross/armv7a/libexec/gcc/arm-linux-gnueabi/4.4.1/cc1 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp -O2 -fno-omit-frame-pointer -mapcs-frame -fno-exceptions -Wall -fno-strict-aliasing -funsigned-char src_file.i
__strcspn_c1 __strcspn_c2 __strcspn_c3 __strspn_c1 __strspn_c2 __strspn_c3 __strpbrk_c2 __strpbrk_c3 __strtok_r_1c __strsep_1c __strsep_2c __strsep_3c gnu_dev_major gnu_dev_minor gnu_dev_makedev pthread_equal vprintf getchar fgetc_unlocked getc_unlocked getchar_unlocked putchar fputc_unlocked putc_unlocked putchar_unlocked getline feof_unlocked ferror_unlocked {GC 5329k -> 4411k} [ .... ]
Analyzing compilation unit
{GC 10931k -> 9472k}Performing interprocedural optimizations
<visibility> <early_local_cleanups> <summary generate> <cp> <inline> <static-var> <pure-const>Assembling functions:
[ ... ]
Program received signal SIGSEGV, Segmentation fault.
0x086a2555 in next_readonly_imm_use (imm=0xbfcea1c4)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-flow-inline.h:423
423 imm->iter_node.next = old->next->next;
(gdb) bt full
#0 0x086a2555 in next_readonly_imm_use (imm=0xbfcea1c4)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-flow-inline.h:423
old = (use_operand_p) 0xb7d08de0
__FUNCTION__ = "next_readonly_imm_use"
#1 0x086a21c5 in add_ssa_edge (var=0xb7d58b98, is_varying=0 '\0')
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-ssa-propagate.c:262
iter = {imm_use = 0xb7d08de0, end_p = 0xb7d58bc0, iter_node = {prev = 0x20e, next = 0x0, loc = {stmt = 0xb7127000, ssa_name = 0xb7127000}, use = 0xbfcea1e8},
next_imm_name = 0x86a22ae}
use_p = (use_operand_p) 0xb7d08de0
__FUNCTION__ = "add_ssa_edge"
#2 0x086a27b8 in simulate_stmt (stmt=0xb7d578e8)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-ssa-propagate.c:353
val = SSA_PROP_INTERESTING
taken_edge = (edge) 0x0
output_name = (tree) 0xb7d58b98
#3 0x086a2e24 in simulate_block (block=0xb7d57924)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-ssa-propagate.c:449
stmt = (gimple) 0xb7d578e8
normal_edge_count = 149532472
e = (edge) 0x8b608f0
normal_edge = (edge) 0xb7ba26b4
ei = {index = 148782160, container = 0x27}
j = {ptr = 0xb7d54b94, seq = 0xb7d54b88, bb = 0xb7d57924}
gsi = {ptr = 0x0, seq = 0x0, bb = 0x0}
#4 0x086a53df in ssa_propagate (visit_stmt=0x8623a6f <copy_prop_visit_stmt>, visit_phi=0x8623bfd <copy_prop_visit_phi_node>)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-ssa-propagate.c:811
dest_block = (basic_block) 0xb7d57924
#5 0x08624875 in execute_copy_prop ()
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-ssa-copy.c:1147
No locals.
#6 0x08447182 in execute_one_pass (pass=0x8de7270)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/passes.c:1279
initializing_dump = 1 '\001'
todo_after = 0
__FUNCTION__ = "execute_one_pass"
#7 0x084473b8 in execute_pass_list (pass=0x8de7270)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/passes.c:1328
__FUNCTION__ = "execute_pass_list"
#8 0x084473d4 in execute_pass_list (pass=0x8d23680)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/passes.c:1329
__FUNCTION__ = "execute_pass_list"
#9 0x085aa590 in tree_rest_of_compilation (fndecl=0xb71e5880)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/tree-optimize.c:420
saved_loc = 9466028
node = (struct cgraph_node *) 0xb7034900
__FUNCTION__ = "tree_rest_of_compilation"
#10 0x087e1bd7 in cgraph_expand_function (node=0xb7034900)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/cgraphunit.c:1047
decl = (tree) 0xb71e5880
__FUNCTION__ = "cgraph_expand_function"
#11 0x087e1d8b in cgraph_expand_all_functions ()
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/cgraphunit.c:1106
node = (struct cgraph_node *) 0xb7034900
order = (struct cgraph_node **) 0x8e637a8
order_pos = 83
new_order_pos = 41
i = 22
__FUNCTION__ = "cgraph_expand_all_functions"
#12 0x087e2311 in cgraph_optimize () at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/cgraphunit.c:1311
No locals.
#13 0x080750b1 in c_write_global_declarations ()
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/c-decl.c:8118
t = (tree) 0x0
__FUNCTION__ = "c_write_global_declarations"
#14 0x08531086 in compile_file () at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/toplev.c:981
No locals.
#15 0x08532c21 in do_compile () at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/toplev.c:2197
No locals.
#16 0x08532c83 in toplev_main (argc=14, argv=0xbfcea604)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/toplev.c:2229
No locals.
#17 0x0811c89a in main (argc=-1211069056, argv=0xb7d578e8)
at /home/winterc/projects/build-tools/poky.2009q3/build/tmp/work/armv7a-linux-gnueabi/gcc-cross-4.4.1+csl-arm-2009q3-67-r0/gcc-4.4/gcc/main.c:35
No locals.
(gdb)
- Follow-Ups:
- Re: [arm-gnu] ICE segfault in 2009q3 (G++ Lite, GNU/Linux EABI)
- From: Mark Mitchell
- Re: [arm-gnu] ICE segfault in 2009q3 (G++ Lite, GNU/Linux EABI)
- Prev by Date: [arm-gnu] Stack seems to be corrupted
- Next by Date: Re: [arm-gnu] ICE segfault in 2009q3 (G++ Lite, GNU/Linux EABI)
- Previous by thread: [arm-gnu] Supporting __softfp compiler directive
- Next by thread: Re: [arm-gnu] ICE segfault in 2009q3 (G++ Lite, GNU/Linux EABI)
- Index(es):