This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ICE seg fault


Daniel Franke wrote:
On Tuesday 31 July 2007 10:22:03 Florian Ladstaedter wrote:
I could reduce the test case quite a lot:
------------------------------------------------
module AtmoIonoSphere
use AtmoIono
use EGOPS_Utilities, ONLY:  dirname
end module AtmoIonoSphere
------------------------------------------------

It now depends on what these modules contain. Could you send me either the corresponding source or the module files (.mod) privately, please?



ok, finally I could hunt it down to a short complete testcase.


First, it seems to be some kind of regression since it compiles with 4.2.1
Second, it does not occur when I don't use separate modules.

Here is the test case:


file egopsutil_red.f90: ------------------------------------------------- MODULE EGOPS_Utilities

IMPLICIT NONE

PUBLIC

CONTAINS

FUNCTION dirname(fullfilename)

   Character(LEN=*),  Intent(In)    :: fullfilename
   Character(LEN=LEN(fullfilename)) :: dirname

dirname = ''

END FUNCTION dirname


END MODULE EGOPS_Utilities -------------------------------------------------


file AtmoIono_red.f90: ------------------------------------------------- MODULE AtmoIono

IMPLICIT NONE

PUBLIC

CHARACTER(LEN=10), PARAMETER :: ComputeDryAtmModel = 'Dry Atm. '

type AtmModel
   character (len=len(ComputeDryAtmModel)) :: moistDryStr
end type AtmModel

END MODULE AtmoIono
-------------------------------------------------


file AtmoIonoSphere_red.f90: ------------------------------------------------- module AtmoIonoSphere

use AtmoIono
use EGOPS_Utilities

end module AtmoIonoSphere
-------------------------------------------------




Compiling with:


gfortran  -c -J../include  -I../include   AtmoIono_red.f90
gfortran  -c -J../include  -I../include   egopsutil_red.f90
gfortran  -c -J../include AtmoIonoSphere_red.f90


gives:


AtmoIonoSphere_red.f90:0: internal compiler error: Segmentation fault





The "Character(LEN=*)" seems to be part of the problem, since using a fixed value here it works.



thanks Florian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]