Bug 200618

Summary: segfault while compiling f90 code
Product: [Fedora] Fedora Reporter: John Pye <john>
Component: gcc4Assignee: Jakub Jelinek <jakub>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 5CC: fxcoudert
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
URL: http://www.conopt.com
Whiteboard:
Fixed In Version: 4.1.1-15 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-08-28 11:03:01 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
tarball containing the problem sources & a makefile none

Description John Pye 2006-07-29 02:22:36 UTC
Description of problem:
I've got a segfault with gfortran, and the error message said I should report it
here. The code I'm compiling is closed source however I have obtained permission 
from the developer, Arne Drud (www.conopt.com) to send the code here. Attached
is only a subset of his code, enough to demonstrate the problem.

Version-Release number of selected component (if applicable):
[john@cruncher2 src]$ rpm -q gcc-gfortran
gcc-gfortran-4.1.1-1.fc5

How reproducible:
Have only tried on one machine, but it happens every time there.

Steps to Reproduce:
1. Unpack the attached tarball
2. cd conopt-3.14/src
3. make
  
Actual results:
[john@cruncher2 src]$ make
gfortran -c -o conopt_data.o conopt_data.f90
gfortran -c -o coutil.o coutil.f90
gfortran -c -o conmsg.o conmsg.f90
conmsg.f90:3313: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
make: *** [conmsg.o] Error 1
[john@cruncher2 src]$


Expected results: (from an FC4 machine)
[john@jdpipe src]$ make
gfortran -c -o conopt_data.o conopt_data.f90
gfortran -c -o coutil.o coutil.f90
gfortran -c -o conmsg.o conmsg.f90
[john@jdpipe src]$ rpm -q gcc-gfortran
gcc-gfortran-4.0.2-8.fc4
[john@jdpipe src]$

Additional info:
So it compiles fine with gcc 4.0.2 but fails with gcc 4.1.1.

Comment 1 John Pye 2006-07-29 02:22:36 UTC
Created attachment 133278 [details]
tarball containing the problem sources & a makefile

Comment 2 John Pye 2006-07-31 12:23:48 UTC
FWIW the software also compiles fine with gfortran 4.0.3:

$ gfortran --version
GNU Fortran 95 (GCC 4.0.3 (Ubuntu 4.0.3-1ubuntu5))
Copyright (C) 2006 Free Software Foundation, Inc.

Cheers
JP

Comment 3 John Pye 2006-08-01 03:30:17 UTC
I just tested the same code on Windows using the experimental gfortran 4.2.0
commpiler. It still segfaults. I will notify fortran.org.

Comment 4 Jakub Jelinek 2006-08-28 11:03:01 UTC
This is fixed in gcc-4.1.1-15 and above.