This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: gfortran 4.1.2: "internal compiler error: Segmentation fault"
- From: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- To: Rob <spamrefuse at yahoo dot com>
- Cc: fortran at gcc dot gnu dot org
- Date: Sun, 1 Oct 2006 10:35:02 -0700
- Subject: Re: gfortran 4.1.2: "internal compiler error: Segmentation fault"
- References: <20060930171017.GA17455@aon.at> <20061001061439.83685.qmail@web33306.mail.mud.yahoo.com>
On Sat, Sep 30, 2006 at 11:14:39PM -0700, Rob wrote:
>
> > On Fri, Sep 29, 2006 at 03:49:37PM -0700, Rob wrote:
> > >
> > >Hi,
> > >
> > >I have compile GCC 4.1.2 (prerelease) on an Alpha
> > >system with CentOS 4 (clone of Redhat Enterprise).
> > >
> > >The required file to reproduce this problem are
> > >here: http://surfion.snu.ac.kr/~lahaye/gcc/
> >
> > Please reduce this to something that doesn't look
> > like parts of vasp ;)
> > I compiled (and ran) a current vasp.4.6 with
> > gfortran a while ago and it did work fine.
> >
> > I can confirm that, however, it currently fails for
> > this reduced (and not vasp related) testcase:
> >
> > $ cat no.f90
> > MODULE MOD1
> > CONTAINS
> > SUBROUTINE SUB1(arg)
> > IMPLICIT NONE
> > CHARACTER (LEN=*), OPTIONAL :: arg
> > IF (PRESENT(arg)) WRITE(0,*) 'arg was ', arg
> > STOP
> > END SUBROUTINE SUB1
> > SUBROUTINE SUB2
> > CALL SUB1
> > END SUBROUTINE SUB2
> > END MODULE
> > $ gfortran-4.2-HEAD -c no.f90
> > no.f90: In function 'sub2':
> > no.f90:3: internal compiler error: Segmentation
> > fault
>
> Yes, indeed I can now confirm this too.
> Moreover, if you replace
> CALL SUB1
> by
> CALL SUB1("")
> the segfault goes away.
> This way I can temporarily bypass this problem
> with gfortran.
>
> Also, this is not in the trunk, but in the
> GCC 1.4.2 svn branch. In my case:
>
> $ gfortran --version
> GNU Fortran 95 (GCC) 4.1.2 20061001 (prerelease)
>
> Regards,
> Rob.
Can you submit a bug report in GCC's bugzilla so that
this doesn't get lost?
--
Steve