http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52622
--- Comment #2 from Adrian Prantl <adrian at llnl dot gov> 2012-03-20 15:33:40 UTC --- I'm getting the error with both gcc 4.6.2 and 4.6.3 Below is the stack trace. Program received signal SIGSEGV, Segmentation fault. resolve_symbol (sym=0x14091b0) at ../../gcc-4.6.2/gcc/fortran/resolve.c:12412 12412 sym->formal_ns->refs++; (gdb) l 12407 formal = formal->next; 12408 12409 if (formal) 12410 { 12411 sym->formal_ns = formal->sym->ns; 12412 sym->formal_ns->refs++; 12413 } 12414 } 12415 12416 /* Check threadprivate restrictions. */ (gdb) bt #0 resolve_symbol (sym=0x14091b0) at ../../gcc-4.6.2/gcc/fortran/resolve.c:12412 #1 0x000000000052f157 in traverse_ns (st=<value optimized out>, func=0x511340 <resolve_symbol>) at ../../gcc-4.6.2/gcc/fortran/symbol.c:3333 #2 0x000000000052f146 in traverse_ns (st=<value optimized out>, func=0x511340 <resolve_symbol>) at ../../gcc-4.6.2/gcc/fortran/symbol.c:3330 #3 0x000000000051bd4c in resolve_types (ns=0x14087b0) at ../../gcc-4.6.2/gcc/fortran/resolve.c:13543 #4 0x000000000051be28 in resolve_types (ns=0x13cd6e0) at ../../gcc-4.6.2/gcc/fortran/resolve.c:13554 #5 0x0000000000510bf4 in gfc_resolve (ns=0x13cd6e0) at ../../gcc-4.6.2/gcc/fortran/resolve.c:13642 #6 gfc_resolve (ns=0x13cd6e0) at ../../gcc-4.6.2/gcc/fortran/resolve.c:13630 #7 0x0000000000506229 in gfc_parse_file () at ../../gcc-4.6.2/gcc/fortran/parse.c:4404 #8 0x000000000053f366 in gfc_be_parse_file () at ../../gcc-4.6.2/gcc/fortran/f95-lang.c:250 #9 0x000000000079d6fc in compile_file (argc=13, argv=0x7fffffffdfc8) at ../../gcc-4.6.2/gcc/toplev.c:579 #10 do_compile (argc=13, argv=0x7fffffffdfc8) at ../../gcc-4.6.2/gcc/toplev.c:1900 ---Type <return> to continue, or q <return> to quit--- #11 toplev_main (argc=13, argv=0x7fffffffdfc8) at ../../gcc-4.6.2/gcc/toplev.c:1963 #12 0x00007ffff7874c4d in __libc_start_main (main=<value optimized out>, argc=<value optimized out>, ubp_av=<value optimized out>, init=<value optimized out>, fini=<value optimized out>, rtld_fini=<value optimized out>, stack_end=0x7fffffffdfb8) at libc-start.c:226 #13 0x000000000049f9b5 in _start () (gdb)