------- Comment #11 from dominiq at lps dot ens dot fr 2010-02-27 10:35 ------- With the patch in comment #10, the tests in pr40440 (the original one and the one in comment #2 give an ICE:
Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000000 gfc_trans_assignment (expr1=0x142a32110, expr2=0x0, init_flag=0 '\0', dealloc=0 '\0') at ../../work/gcc/fortran/trans-expr.c:5380 5380 if (expr2->expr_type == EXPR_FUNCTION && expr2->rank > 0) (gdb) bt #0 gfc_trans_assignment (expr1=0x142a32110, expr2=0x0, init_flag=0 '\0', dealloc=0 '\0') at ../../work/gcc/fortran/trans-expr.c:5380 #1 0x00000001000c2304 in gfc_init_default_dt (sym=0x142a0a170, body=0x0, dealloc=0 '\0') at ../../work/gcc/fortran/trans-decl.c:3011 #2 0x00000001000b1810 in gfc_trans_deferred_array (sym=0x142a0a170, body=0x1429dc820) at ../../work/gcc/fortran/trans-array.c:6258 #3 0x00000001000c2aa1 in gfc_trans_deferred_vars (proc_sym=0x1428fbb60, fnbody=<value temporarily unavailable, due to optimizations>) at ../../work/gcc/fortran/trans-decl.c:3159 #4 0x00000001000c3be4 in gfc_generate_function_code (ns=<value temporarily unavailable, due to optimizations>) at ../../work/gcc/fortran/trans-decl.c:4400 #5 0x00000001000a79eb in gfc_generate_module_code (ns=<value temporarily unavailable, due to optimizations>) at ../../work/gcc/fortran/trans.c:1382 #6 0x000000010006955f in gfc_parse_file () at ../../work/gcc/fortran/parse.c:4228 #7 0x00000001000a27fc in gfc_be_parse_file (set_yydebug=<value temporarily unavailable, due to optimizations>) at ../../work/gcc/fortran/f95-lang.c:239 #8 0x00000001006d5c9a in toplev_main (argc=2, argv=0x7fff5fbfda18) at ../../work/gcc/toplev.c:1053 #9 0x00000001000010a4 in start () Otherwise all my other tests passed and regression testing went fine. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43178