public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/25532]  New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
@ 2005-12-22  9:42 martin at mpa-garching dot mpg dot de
  2005-12-22  9:43 ` [Bug fortran/25532] " martin at mpa-garching dot mpg dot de
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: martin at mpa-garching dot mpg dot de @ 2005-12-22  9:42 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2290 bytes --]

Today's gfortran from trunk ICE's on the attached testcase:

martin@linux:~/tmp> gfortran -v -c test.F90
Using built-in specs.
Target: x86_64-unknown-linux-gnu
Configured with: /home/martin/software/gcc/configure --quiet
--prefix=/home/martin/software/ugcc --enable-languages=c++,fortran
--enable-checking=release
Thread model: posix
gcc version 4.2.0 20051222 (experimental)
 /home/martin/software/ugcc/libexec/gcc/x86_64-unknown-linux-gnu/4.2.0/cc1 -E
-lang-fortran -traditional-cpp -D_LANGUAGE_FORTRAN -quiet -v test.F90 -mtune=k8
-o /tmp/ccCu0SZq.f95
ignoring nonexistent directory
"/home/martin/software/ugcc/lib/gcc/x86_64-unknown-linux-gnu/4.2.0/../../../../x86_64-unknown-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /home/martin/software/ugcc/include
 /home/martin/software/ugcc/lib/gcc/x86_64-unknown-linux-gnu/4.2.0/include
 /usr/include
End of search list.
 /home/martin/software/ugcc/libexec/gcc/x86_64-unknown-linux-gnu/4.2.0/f951
/tmp/ccCu0SZq.f95 -quiet -dumpbase test.F90 -mtune=k8 -auxbase test -version -o
/tmp/ccCKf8wI.s
GNU F95 version 4.2.0 20051222 (experimental) (x86_64-unknown-linux-gnu)
        compiled by GNU C version 4.2.0 20051222 (experimental).
GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=127998
test.F90: In function ‘inithermo’:
test.F90:847: internal compiler error: in gfc_conv_component_ref, at
fortran/trans-expr.c:269
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

This problem must have been introduced in the last few days.
Sorry for the long testcase, I can try to reduce further in a few days.


-- 
           Summary: [gfortran] ICE in gfc_conv_component_ref, at
                    fortran/trans-expr.c:269
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: martin at mpa-garching dot mpg dot de
 GCC build triplet: x86_64-unknown-linux-gnu
  GCC host triplet: x86_64-unknown-linux-gnu
GCC target triplet: x86_64-unknown-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
@ 2005-12-22  9:43 ` martin at mpa-garching dot mpg dot de
  2005-12-22 19:49 ` [Bug fortran/25532] [gfortran, regression] " eedelman at gcc dot gnu dot org
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: martin at mpa-garching dot mpg dot de @ 2005-12-22  9:43 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from martin at mpa-garching dot mpg dot de  2005-12-22 09:43 -------
Created an attachment (id=10549)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=10549&action=view)
test case


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
  2005-12-22  9:43 ` [Bug fortran/25532] " martin at mpa-garching dot mpg dot de
@ 2005-12-22 19:49 ` eedelman at gcc dot gnu dot org
  2005-12-23 17:58 ` eedelman at gcc dot gnu dot org
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: eedelman at gcc dot gnu dot org @ 2005-12-22 19:49 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from eedelman at gcc dot gnu dot org  2005-12-22 19:49 -------
With GNU Fortran 95 (GCC) 4.2.0 20051221 it works (I get a lot of 'undefined
reference' messages, but no ICE:s).  But with 20051222 I get the same ICE
message that Martin gets.  So it seems the problem was introduced within the
last 24 hours.  Confiremd.


-- 

eedelman at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2005-12-22 19:49:51
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
  2005-12-22  9:43 ` [Bug fortran/25532] " martin at mpa-garching dot mpg dot de
  2005-12-22 19:49 ` [Bug fortran/25532] [gfortran, regression] " eedelman at gcc dot gnu dot org
@ 2005-12-23 17:58 ` eedelman at gcc dot gnu dot org
  2005-12-26 21:20 ` eedelman at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: eedelman at gcc dot gnu dot org @ 2005-12-23 17:58 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from eedelman at gcc dot gnu dot org  2005-12-23 17:58 -------
(In reply to comment #2)
> So it seems the problem was introduced within the last 24 hours.

To be a bit more precise: works with revision 108902, ICE:s with revision
108943.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (2 preceding siblings ...)
  2005-12-23 17:58 ` eedelman at gcc dot gnu dot org
@ 2005-12-26 21:20 ` eedelman at gcc dot gnu dot org
  2005-12-27  5:53 ` pault at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: eedelman at gcc dot gnu dot org @ 2005-12-26 21:20 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from eedelman at gcc dot gnu dot org  2005-12-26 21:20 -------
Here's a reduced testcase:

----
module ModelParams
        implicit none

        type ReionizationParams
             real   :: fraction
        end type ReionizationParams

        type CAMBparams
             type(ReionizationParams) :: Reion
         end type CAMBparams

        type(CAMBparams) CP
end module ModelParams


module ThermoData
    use ModelParams
    implicit none

contains

    subroutine inithermo()
        use ModelParams
        if (0 < CP%Reion%fraction) then
        end if
    end subroutine inithermo

    subroutine SetTimeSteps
        if (0 < CP%Reion%fraction) then
        end if
    end subroutine SetTimeSteps

end module ThermoData
--------


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (3 preceding siblings ...)
  2005-12-26 21:20 ` eedelman at gcc dot gnu dot org
@ 2005-12-27  5:53 ` pault at gcc dot gnu dot org
  2005-12-28 11:18 ` pault at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-12-27  5:53 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from pault at gcc dot gnu dot org  2005-12-27 05:53 -------
There are three different, temporary work-arounds:

(i) Remove all "use ModelParams" from the contained procedures;
(ii) Add a "use ModelParams" to subroutine SetTimeSteps; or
(iii) Change the order of the contained procedures.

In the meantime, I will sort out a solution.

Paul

> 
> ----
> module ModelParams
>         implicit none
> 
>         type ReionizationParams
>              real   :: fraction
>         end type ReionizationParams
> 
>         type CAMBparams
>              type(ReionizationParams) :: Reion
>          end type CAMBparams
> 
>         type(CAMBparams) CP
> end module ModelParams
> 
> 
> module ThermoData
>     use ModelParams
>     implicit none
> 
> contains
> 
>     subroutine inithermo()
>         use ModelParams
>         if (0 < CP%Reion%fraction) then
>         end if
>     end subroutine inithermo
> 
>     subroutine SetTimeSteps
>         if (0 < CP%Reion%fraction) then
>         end if
>     end subroutine SetTimeSteps
> 
> end module ThermoData
> --------
> 


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (4 preceding siblings ...)
  2005-12-27  5:53 ` pault at gcc dot gnu dot org
@ 2005-12-28 11:18 ` pault at gcc dot gnu dot org
  2005-12-28 11:36 ` martin at mpa-garching dot mpg dot de
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-12-28 11:18 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from pault at gcc dot gnu dot org  2005-12-28 11:18 -------
I have just submitted a patch for this, which I intend to commit tomorrow
morning.

Thank you for reporting the bug I hope that the inconvenience is outweighed by
gfortran handling derived types correctly.

Paul


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (5 preceding siblings ...)
  2005-12-28 11:18 ` pault at gcc dot gnu dot org
@ 2005-12-28 11:36 ` martin at mpa-garching dot mpg dot de
  2005-12-29  6:11 ` pault at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: martin at mpa-garching dot mpg dot de @ 2005-12-28 11:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from martin at mpa-garching dot mpg dot de  2005-12-28 11:36 -------
(In reply to comment #6)
> I have just submitted a patch for this, which I intend to commit tomorrow
> morning.

Great, thanks!

> Thank you for reporting the bug I hope that the inconvenience is outweighed by
> gfortran handling derived types correctly.

Absolutely! I'm not using gfortran for production at the moment, but run
regular tests with our local codes. I'm really looking forward to having a
free, standard-conforming, multi-platform and OpenMP-aware F95 compiler soon,
and gfortran is evolving very nicely :)

In your mail to gfortran you mentioned that you wanted to apply the fix to the
4.1-branch as well. Since the problem is not triggered there (I don't know
why), your patch is technically not a regression fix, so it might not be
appropriate there. Just a thought.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (6 preceding siblings ...)
  2005-12-28 11:36 ` martin at mpa-garching dot mpg dot de
@ 2005-12-29  6:11 ` pault at gcc dot gnu dot org
  2005-12-29  6:18 ` pault at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-12-29  6:11 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from pault at gcc dot gnu dot org  2005-12-29 06:11 -------
Subject: Bug 25532

Author: pault
Date: Thu Dec 29 06:11:21 2005
New Revision: 109138

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=109138
Log:
2005-12-29  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/25532
        * trans-types.c (copy_dt_decls_ifequal): Copy declarations for
        components of derived type components by recursing into
        gfc_get_derived_type.

2005-12-29  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/25532
        *gfortran.dg/host_used_types_1.f90: Check that host associated
        derived type components of derived types are properly declared
        in contained procedures.

Added:
    trunk/gcc/testsuite/gfortran.dg/host_used_types_1.f90
Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/trans-types.c
    trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (7 preceding siblings ...)
  2005-12-29  6:11 ` pault at gcc dot gnu dot org
@ 2005-12-29  6:18 ` pault at gcc dot gnu dot org
  2005-12-29  9:12 ` martin at mpa-garching dot mpg dot de
  2006-01-01  6:02 ` pinskia at gcc dot gnu dot org
  10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-12-29  6:18 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from pault at gcc dot gnu dot org  2005-12-29 06:18 -------
Subject: Bug 25532

Author: pault
Date: Thu Dec 29 06:18:23 2005
New Revision: 109139

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=109139
Log:
2005-12-29  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/25532
        * trans-types.c (copy_dt_decls_ifequal): Copy declarations for
        components of derived type components by recursing into
        gfc_get_derived_type.

2005-12-29  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/25532
        *gfortran.dg/host_used_types_1.f90: Check that host associated
        derived type components of derived types are properly declared
        in contained procedures.

        The following tests were not added on the 2005-12-26 commit.

        PR fortran/20889
        * gfortran.dg/pointer_component_type_1.f90: New test.

        PR fortran/25018
        * gfortran.dg/initialization_1.f90: New test.

        PR fortran/19362
        PR fortran/20244
        PR fortran/20864
        PR fortran/25391
        * gfortran.dg/used_dummy_types_1.f90: New test.
        * gfortran.dg/used_dummy_types_2.f90: New test.
        * gfortran.dg/used_dummy_types_3.f90: New test.
        * gfortran.dg/used_dummy_types_4.f90: New test.
        * gfortran.dg/used_dummy_types_5.f90: New test.

        PR fortran/23152
        * gfortran.dg/assumed_shape_nml.f90: New test.
        * gfortran.dg/assumed_size_nml.f90: New test.

        PR fortran/20862
        PR fortran/25053
        PR fortran/25063
        PR fortran/25064
        PR fortran/25066
        PR fortran/25067
        PR fortran/25068
        PR fortran/25307
        * gfortran.dg/io_constraints_1.f90: New test.
        * gfortran.dg/io_constraints_1.f90: New test.

Added:
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/assumed_shape_nml.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/assumed_size_nml.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/host_used_types_1.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/initialization_1.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/io_constraints_1.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/io_constraints_2.f90
   
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/pointer_component_type_1.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/used_dummy_types_1.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/used_dummy_types_2.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/used_dummy_types_3.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/used_dummy_types_4.f90
    branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/used_dummy_types_5.f90
Modified:
    branches/gcc-4_1-branch/gcc/fortran/ChangeLog
    branches/gcc-4_1-branch/gcc/fortran/trans-types.c
    branches/gcc-4_1-branch/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (8 preceding siblings ...)
  2005-12-29  6:18 ` pault at gcc dot gnu dot org
@ 2005-12-29  9:12 ` martin at mpa-garching dot mpg dot de
  2006-01-01  6:02 ` pinskia at gcc dot gnu dot org
  10 siblings, 0 replies; 12+ messages in thread
From: martin at mpa-garching dot mpg dot de @ 2005-12-29  9:12 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from martin at mpa-garching dot mpg dot de  2005-12-29 09:12 -------
I just recompiled and everything works nicely again. Thanks!


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug fortran/25532] [gfortran, regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269
  2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
                   ` (9 preceding siblings ...)
  2005-12-29  9:12 ` martin at mpa-garching dot mpg dot de
@ 2006-01-01  6:02 ` pinskia at gcc dot gnu dot org
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-01-01  6:02 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from pinskia at gcc dot gnu dot org  2006-01-01 06:02 -------
Confirmed as fixed so closing as such.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |4.1.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25532



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2006-01-01  6:02 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-22  9:42 [Bug fortran/25532] New: [gfortran] ICE in gfc_conv_component_ref, at fortran/trans-expr.c:269 martin at mpa-garching dot mpg dot de
2005-12-22  9:43 ` [Bug fortran/25532] " martin at mpa-garching dot mpg dot de
2005-12-22 19:49 ` [Bug fortran/25532] [gfortran, regression] " eedelman at gcc dot gnu dot org
2005-12-23 17:58 ` eedelman at gcc dot gnu dot org
2005-12-26 21:20 ` eedelman at gcc dot gnu dot org
2005-12-27  5:53 ` pault at gcc dot gnu dot org
2005-12-28 11:18 ` pault at gcc dot gnu dot org
2005-12-28 11:36 ` martin at mpa-garching dot mpg dot de
2005-12-29  6:11 ` pault at gcc dot gnu dot org
2005-12-29  6:18 ` pault at gcc dot gnu dot org
2005-12-29  9:12 ` martin at mpa-garching dot mpg dot de
2006-01-01  6:02 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).