The current gfortran segfaults when compiling the following code program test call foo ( (/"bar"/) ) end program ~/tmp>gfortran -v gfbug.f90 Driving: gfortran -v gfbug.f90 -lgfortranbegin -lgfortran -lm -shared-libgcc Reading specs from /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.0.0/specs Configured with: /scratch/gcc/configure --quiet --prefix=/afs/mpa/data/martin/ugcc --enable-languages=c++,f95 --with-gmp=/afs/mpa/data/martin/mygmp Thread model: posix gcc version 4.0.0 20041021 (experimental) /afs/mpa/data/martin/ugcc/libexec/gcc/i686-pc-linux-gnu/4.0.0/f951 gfbug.f90 -quiet -dumpbase gfbug.f90 -mtune=pentiumpro -auxbase gfbug -version -o /tmp/ccwl5Yg5.s GNU F95 version 4.0.0 20041021 (experimental) (i686-pc-linux-gnu) compiled by GNU C version 4.0.0 20041021 (experimental). GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096 gfbug.f90: In function 'MAIN__': gfbug.f90:2: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://gcc.gnu.org/bugs.html> for instructions.
Confirmed, I thought I saw something like this before.
Maybe you are thinking of http://gcc.gnu.org/ml/fortran/2004-10/msg00172.html But that wasn't a segfault.
Subject: Bug 18109 CVSROOT: /cvs/gcc Module name: gcc Branch: apple-gcc_os_35-branch Changes by: dalej@gcc.gnu.org 2005-02-14 23:24:52 Modified files: gcc : ChangeLog.apple-ppc gcc/config/i386: i386.md Log message: 2005-02-14 Dale Johannesen <dalej@apple.com> Radar 4003603 PR 18109 (Same as 3838108/3876378 in 4.0.) * config/i386/i386.md (movqi_1): Don't use 4-byte load when unsafe. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.apple-ppc.diff?cvsroot=gcc&only_with_tag=apple-gcc_os_35-branch&r1=1.1.2.190.2.16&r2=1.1.2.190.2.17 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/i386/i386.md.diff?cvsroot=gcc&only_with_tag=apple-gcc_os_35-branch&r1=1.374.2.42.2.5&r2=1.374.2.42.2.5.2.1
Please ignore comment #3, I had the bug number wrong.
Subject: Bug 18109 CVSROOT: /cvs/gcc Module name: gcc Branch: apple-ppc-branch Changes by: dalej@gcc.gnu.org 2005-02-17 01:56:12 Modified files: gcc : ChangeLog.apple-ppc cse.c simplify-rtx.c recog.c basic-block.h gcc/config/i386: i386.md Log message: 2005-02-16 Dale Johannesen <dalej@apple.com> Radar 4006687 PR 17767 et al (fix from mainline) * cse.c (fold_rtx) [RTX_COMPARE, RTX_COMM_COMPARE]: Don't attempt any simplifications of vector mode comparison operators. * simplify-rtx.c (simplify_relational_operation): Fix variable name. 2005-02-15 Dale Johannesen <dalej@apple.com> Radar 3991611 Radar 3990578 PRs 19084 and 19348 (fix from mainline) * recog.c (peephole2_optimize): Do global life update if some peephole decides it doesn't need at least one of its inputs and that change influences liveness at the start of the basic block. * basic-block.h (EXECUTE_IF_AND_COMPL_IN_REG_SET): Needs 2 REGSET arguments instead of 1. 2005-02-15 Dale Johannesen <dalej@apple.com> Radar 3876378 Radar 3838108 PR 18109 (fix from mainline) * config/i386/i386.md (movhi_1): Remove previous attempt at a fix. (movqi_1): Ditto. Don't use 4-byte load when unsafe. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.apple-ppc.diff?cvsroot=gcc&only_with_tag=apple-ppc-branch&r1=1.1.2.308&r2=1.1.2.309 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cse.c.diff?cvsroot=gcc&only_with_tag=apple-ppc-branch&r1=1.229.2.32.2.13&r2=1.229.2.32.2.14 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/simplify-rtx.c.diff?cvsroot=gcc&only_with_tag=apple-ppc-branch&r1=1.107.2.31.2.11&r2=1.107.2.31.2.12 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/recog.c.diff?cvsroot=gcc&only_with_tag=apple-ppc-branch&r1=1.159.2.24.2.8&r2=1.159.2.24.2.9 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/basic-block.h.diff?cvsroot=gcc&only_with_tag=apple-ppc-branch&r1=1.153.2.48.2.10&r2=1.153.2.48.2.11 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/i386/i386.md.diff?cvsroot=gcc&only_with_tag=apple-ppc-branch&r1=1.374.2.42.2.7&r2=1.374.2.42.2.8
Subject: Bug 18109 CVSROOT: /cvs/gcc Module name: gcc Changes by: pault@gcc.gnu.org 2005-05-31 17:19:12 Modified files: gcc/fortran : ChangeLog trans-array.c trans-expr.c Log message: 2005-05-30 Paul Thomas <pault@gcc.gnu.org> PR fortran/18109 PR fortran/18283 PR fortran/19107 * fortran/trans-array.c (gfc_conv_expr_descriptor): Obtain the string length from the expression typespec character length value and set temp_ss->stringlength and backend_decl. Obtain the tree expression from gfc_conv_expr rather than gfc_conv_expr_val. Dereference the expression to obtain the character. * fortran/trans-expr.c (gfc_conv_component_ref): Remove the dereference of scalar character pointer structure components. * fortran/trans-expr.c (gfc_trans_subarray_assign): Obtain the string length for the structure component from the component expression. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/ChangeLog.diff?cvsroot=gcc&r1=1.444&r2=1.445 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/trans-array.c.diff?cvsroot=gcc&r1=1.46&r2=1.47 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/trans-expr.c.diff?cvsroot=gcc&r1=1.47&r2=1.48
Subject: Bug 18109 CVSROOT: /cvs/gcc Module name: gcc Branch: gcc-4_0-branch Changes by: pault@gcc.gnu.org 2005-06-05 08:59:18 Modified files: gcc/fortran : ChangeLog trans-array.c trans-expr.c Log message: 005-05-31 Paul Thomas <pault@gcc.gnu.org> PR fortran/18109 PR fortran/18283 PR fortran/19107 PR fortran/16939 PR fortran/17192 PR fortran/17193 PR fortran/17202 PR fortran/18689 PR fortran/18890 * fortran/trans-array.c (gfc_conv_expr_descriptor): Obtain the string length from the expression typespec character length value and set temp_ss->stringlength and backend_decl. Obtain the tree expression from gfc_conv_expr rather than gfc_conv_expr_val. Dereference the expression to obtain the character. * fortran/trans-array.c (gfc_conv_resolve_dependencies): Add string length to temp_ss for character pointer array assignments. * fortran/trans-expr.c (gfc_conv_component_ref): Remove the dereference of scalar character pointer structure components. * fortran/trans-expr.c (gfc_trans_subarray_assign): Obtain the string length for the structure component from the component expression. * fortran/trans-expr.c (gfc_conv_variable): Correct errors in dereferencing of characters and character pointers. * fortran/trans-expr.c (gfc_conv_function_call): Provide string length as return argument for various kinds of handling of return. Return a char[]* temporary for character pointer functions and dereference the temporary upon return. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.335.2.66&r2=1.335.2.67 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/trans-array.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.39.2.3&r2=1.39.2.4 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/trans-expr.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.38.2.4&r2=1.38.2.5
Fixed in 4.0 and 4.1