From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 85658 invoked by alias); 19 Mar 2015 10:23:31 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 85576 invoked by uid 48); 19 Mar 2015 10:23:28 -0000 From: "daniel.price at monash dot edu" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/65469] New: ICE on bad code Date: Thu, 19 Mar 2015 10:37:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 4.9.2 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: daniel.price at monash dot edu X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-03/txt/msg01939.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65469 Bug ID: 65469 Summary: ICE on bad code Product: gcc Version: 4.9.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: daniel.price at monash dot edu Created attachment 35062 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35062&action=edit code that produces the internal compiler error Dear gfortran folks, Attached is a short test case of (wrong) code I happened to produce that triggers an "internal compiler error" and a seg fault. I've got it down to just 9 lines of code. The code should obviously fail to compile, but I thought you might like to fix the ICE and the seg fault... Daniel Output as follows: $ gfortran-mp-4.9 -o ice.o -c ice.f90 ice.f90:7.17: type(block_type) :: my_block 1 Error: Derived type 'block_type' at (1) is being used before it is defined f951: internal compiler error: Segmentation fault: 11 f951: internal compiler error: Abort trap: 6 gfortran-mp-4.9: internal compiler error: Abort trap: 6 (program f951) Abort trap: 6 ----- Version info (also fails with gfortran v4.8): ----- $ gfortran-mp-4.9 -v Using built-in specs. COLLECT_GCC=gfortran-mp-4.9 COLLECT_LTO_WRAPPER=/opt/local/libexec/gcc/x86_64-apple-darwin14/4.9.2/lto-wrapper Target: x86_64-apple-darwin14 Configured with: /opt/local/var/macports/build/_opt_mports_dports_lang_gcc49/gcc49/work/gcc-4.9.2/configure --prefix=/opt/local --build=x86_64-apple-darwin14 --enable-languages=c,c++,objc,obj-c++,lto,fortran,java --libdir=/opt/local/lib/gcc49 --includedir=/opt/local/include/gcc49 --infodir=/opt/local/share/info --mandir=/opt/local/share/man --datarootdir=/opt/local/share/gcc-4.9 --with-local-prefix=/opt/local --with-system-zlib --disable-nls --program-suffix=-mp-4.9 --with-gxx-include-dir=/opt/local/include/gcc49/c++/ --with-gmp=/opt/local --with-mpfr=/opt/local --with-mpc=/opt/local --with-isl=/opt/local --disable-isl-version-check --with-cloog=/opt/local --disable-cloog-version-check --enable-stage1-checking --disable-multilib --enable-lto --enable-libstdcxx-time --with-as=/opt/local/bin/as --with-ld=/opt/local/bin/ld --with-ar=/opt/local/bin/ar --with-bugurl=https://trac.macports.org/newticket --with-pkgversion='MacPorts gcc49 4.9.2_1' Thread model: posix gcc version 4.9.2 (MacPorts gcc49 4.9.2_1)