When compiling a small file with standard flags the compiler crashes. This seems to be related to a WHERE construct. The code is accepted without warnings by e.g. Intel fortran compiler and others. The version of gfortran is 4.2.0 20060819
Created attachment 12201 [details] Valid code snippet that causes ICE gfortran -c tst.f90 tst.f90:0: 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.
Oskar, This works for me with gcc-4.2.0 20060905; I know of nothing that would have effected this change so I am at a bit of a loss. I hung a main program on it and checked the output too. Paul
Paul, the code fails with troutmask:kargl[205] gfc --version GNU Fortran 95 (GCC) 4.2.0 20060711 (experimental) Copyright (C) 2006 Free Software Foundation, Inc. but works with troutmask:sgk[248] gfc4x --version GNU Fortran 95 (GCC) 4.2.0 20060906 (experimental) Copyright (C) 2006 Free Software Foundation, Inc. On a quick scan of ChangeLog, I did not see an entry that jumps out that fixed/caused the problem. Oskar, Can you update to a newer version and verify the code works?
Oskar, We believe that this bug is "fixed"; however, I will take you tst.f90 and put it in the gfortran testsuite, since we do not know what moved to produce both the regression and the "fix". As I said to the list, we will be very grateful if you would submit any problems that you might have in the future. Paul Thomas
Subject: Re: ICE: Segmentation fault on valid code Yes that's fine with me. I don't have access to the computer where I originally noticed the problem until the end of the week so I haven't been able to try any later snapshot version. I have compiled the latest trunk on a different machine (i686) and have verified that the testcase compiles without crash there. So it appears to be fixed. Thanks for the response! /Oskar pault at gcc dot gnu dot org wrote: > ------- Comment #4 from pault at gcc dot gnu dot org 2006-09-12 08:59 ------- > Oskar, > > We believe that this bug is "fixed"; however, I will take you tst.f90 and put > it in the gfortran testsuite, since we do not know what moved to produce both > the regression and the "fix". > > As I said to the list, we will be very grateful if you would submit any > problems that you might have in the future. > > Paul Thomas > > >
Subject: Bug 28971 Author: pault Date: Tue Sep 12 19:38:48 2006 New Revision: 116904 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=116904 Log: 2006-09-12 Paul Thomas <pault@gcc.gnu.org> PR fortran/28971 gfortran.dg/pr28971.f90: New test to act as a backstop in case this undiagnosed regression reappears. Added: trunk/gcc/testsuite/gfortran.dg/pr28971.f90 Modified: trunk/gcc/testsuite/ChangeLog