[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #21 from Dominique d'Humieres --- > I just submitted a new bug. It is a pity that my code cannot be compiled > with gfortran 4.9 and above for more than a year now.. (Part of) your code should compile with the 5.3.0 release.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #22 from kargl at gcc dot gnu.org --- (In reply to Hossein Talebi from comment #20) > I just submitted a new bug. It is a pity that my code cannot be compiled > with gfortran 4.9 and above for more than a year now.. It is comments like the above that inspire me to invest my time in gfortran. Thanks for your support.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #23 from Hossein Talebi --- Thank you also for the great work and such a nice compiler. I should have actually noticed this a lot sooner but I was trying to keep my code compiling with gcc 4.8. > It is comments like the above that inspire me to invest my > time in gfortran. Thanks for your support. > >
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #18 from Hossein Talebi --- I am now trying this bug and the Bug 68415 with the new GCC from trunc and it is fine. Nevertheless, this other code does not compile. (gcc version 6.0.0 20151129 (experimental)) Module part_base2_class implicit none type :: ty_moc1 integer l end type ty_moc1 integer,parameter :: MAX_NUM_ELEMENT_TYPE=32 type :: ty_element_index2 class(ty_moc1),allocatable :: element class(ty_moc1),allocatable :: element_th(:) endtype ty_element_index2 type :: ty_part_base2 type(ty_element_index2)::element_index(MAX_NUM_ELEMENT_TYPE) end type ty_part_base2 class(ty_part_base2),allocatable :: part_tmp_obj End Module part_base2_class
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #19 from kargl at gcc dot gnu.org --- (In reply to Hossein Talebi from comment #18) > I am now trying this bug and the Bug 68415 with the new GCC from trunc and > it is fine. Nevertheless, this other code does not compile. > (gcc version 6.0.0 20151129 (experimental)) > Please open a new bug report. Add a comment with code exhibiting a bug to a CLOSED bug report is a good way to get the report ignored.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #20 from Hossein Talebi --- I just submitted a new bug. It is a pity that my code cannot be compiled with gfortran 4.9 and above for more than a year now.. On Fri, Dec 11, 2015 at 9:01 PM, kargl at gcc dot gnu.org < gcc-bugzi...@gcc.gnu.org> wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 > > --- Comment #19 from kargl at gcc dot gnu.org --- > (In reply to Hossein Talebi from comment #18) > > I am now trying this bug and the Bug 68415 with the new GCC from trunc > and > > it is fine. Nevertheless, this other code does not compile. > > (gcc version 6.0.0 20151129 (experimental)) > > > > Please open a new bug report. Add a comment with code > exhibiting a bug to a CLOSED bug report is a good way > to get the report ignored. > > -- > You are receiving this mail because: > You are on the CC list for the bug. >
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Dominique d'Humieres changed: What|Removed |Added CC||talebi.hossein at gmail dot com --- Comment #17 from Dominique d'Humieres --- *** Bug 68415 has been marked as a duplicate of this bug. ***
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #15 from Paul Thomas --- Author: pault Date: Wed Nov 4 20:00:19 2015 New Revision: 229777 URL: https://gcc.gnu.org/viewcvs?rev=229777=gcc=rev Log: 2015-01-25 Paul ThomasBackported from trunk. PR fortran/67171 * trans-array.c (structure_alloc_comps): On deallocation of class components, reset the vptr to the declared type vtable and reset the _len field of unlimited polymorphic components. *trans-expr.c (gfc_find_and_cut_at_last_class_ref): Bail out on allocatable component references to the right of part reference with non-zero rank and return NULL. (gfc_reset_vptr): Simplify this function by using the function gfc_get_vptr_from_expr. Return if the vptr is NULL_TREE. (gfc_reset_len): If gfc_find_and_cut_at_last_class_ref returns NULL return. 2015-01-25 Paul Thomas Backported from trunk. PR fortran/67171 * gfortran.dg/allocate_with_source_12.f03: New test Backported from trunk. PR fortran/61819 * gfortran.dg/allocate_with_source_13.f03: New test Backported from trunk. PR fortran/61830 * gfortran.dg/allocate_with_source_14.f03: New test Backported from trunk. PR fortran/67933 * gfortran.dg/allocate_with_source_15.f03: New test Added: branches/gcc-5-branch/gcc/testsuite/gfortran.dg/allocate_with_source_12.f03 branches/gcc-5-branch/gcc/testsuite/gfortran.dg/allocate_with_source_13.f03 branches/gcc-5-branch/gcc/testsuite/gfortran.dg/allocate_with_source_14.f03 branches/gcc-5-branch/gcc/testsuite/gfortran.dg/allocate_with_source_15.f03 Modified: branches/gcc-5-branch/gcc/fortran/ChangeLog branches/gcc-5-branch/gcc/fortran/trans-array.c branches/gcc-5-branch/gcc/fortran/trans-expr.c branches/gcc-5-branch/gcc/testsuite/ChangeLog
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Paul Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #16 from Paul Thomas --- Fixed on trunk and 5 branch. Thanks for the report. Paul
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Dominique d'Humieres changed: What|Removed |Added Status|RESOLVED|NEW Resolution|DUPLICATE |--- --- Comment #12 from Dominique d'Humieres --- > See comment 4 of pr59765 for the origin of the problem. > > *** This bug has been marked as a duplicate of bug 59765 *** I don't remember why I have resolved this PR as a duplicate of pr59765. The ICE is still there with 5.2.0 and trunk (6.0 at r229261). If a duplicate it is more a duplicate of pr61830: the ICE is fixed by the patch submitted at https://gcc.gnu.org/ml/fortran/2015-10/msg00117.html.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #13 from Paul Thomas --- Author: pault Date: Sun Oct 25 21:31:12 2015 New Revision: 229303 URL: https://gcc.gnu.org/viewcvs?rev=229303=gcc=rev Log: 2015-01-25 Paul ThomasPR fortran/67171 * trans-array.c (structure_alloc_comps): On deallocation of class components, reset the vptr to the declared type vtable and reset the _len field of unlimited polymorphic components. *trans-expr.c (gfc_find_and_cut_at_last_class_ref): Bail out on allocatable component references to the right of part reference with non-zero rank and return NULL. (gfc_reset_vptr): Simplify this function by using the function gfc_get_vptr_from_expr. Return if the vptr is NULL_TREE. (gfc_reset_len): If gfc_find_and_cut_at_last_class_ref returns NULL return. * trans-stmt.c (gfc_trans_allocate): Rely on the use of gfc_trans_assignment if expr3 is a variable expression since this deals correctly with array sections. 2015-01-25 Paul Thomas PR fortran/67171 * gfortran.dg/allocate_with_source_12.f03: New test PR fortran/61819 * gfortran.dg/allocate_with_source_13.f03: New test PR fortran/61830 * gfortran.dg/allocate_with_source_14.f03: New test Added: trunk/gcc/testsuite/gfortran.dg/allocate_with_source_12.f03 trunk/gcc/testsuite/gfortran.dg/allocate_with_source_13.f03 trunk/gcc/testsuite/gfortran.dg/allocate_with_source_14.f03 Modified: trunk/gcc/fortran/ChangeLog trunk/gcc/fortran/trans-array.c trunk/gcc/fortran/trans-expr.c trunk/gcc/fortran/trans-stmt.c trunk/gcc/testsuite/ChangeLog
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Paul Thomas changed: What|Removed |Added CC||pault at gcc dot gnu.org --- Comment #14 from Paul Thomas --- Fixed on trunk - I'll see what I can do for the earlier branches. Thanks for the report Paul
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Dominique d'Humieres dominiq at lps dot ens.fr changed: What|Removed |Added CC||janus at gcc dot gnu.org Summary|ICE in |[4.9/4.10 Regression] ICE |gfc_conv_descriptor_data_ge |in |t |gfc_conv_descriptor_data_ge ||t --- Comment #6 from Dominique d'Humieres dominiq at lps dot ens.fr --- Code works with 4.8.3, so this is a regression. Confirmed: revision r206362 (2014-01-06) is OK, r206567 (2014-01-12) gives the ICE. Likely r206379 (pr59589).
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #7 from Salvatore Filippone sfilippone at uniroma2 dot it --- The original code leaks memory like a sieve, and looks suspiciously similar to PR55603. It is just possible that the whole area of function results needs to be reviewed (I guess that would be no small task) Salvatore
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #8 from Dominique d'Humieres dominiq at lps dot ens.fr --- The following PRs give an ICE at the same place: pr54784, pr59765, pr60529, and pr61766.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 --- Comment #9 from Dominique d'Humieres dominiq at lps dot ens.fr --- Note that the original test of pr54784 now gives the same ICE and the change of behavior is in the range given in comment 6.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Dominique d'Humieres dominiq at lps dot ens.fr changed: What|Removed |Added CC||damian at sourceryinstitute dot or ||g --- Comment #10 from Dominique d'Humieres dominiq at lps dot ens.fr --- Likely r206379 (pr59589). If I partially revert r206379, the ICEs for pr54784, pr59765, pr60529, pr61766, pr61819, and pr61822 are gone. Indeed the memory leak for pr59589 reappears and I get an ICE at trans-array.c:146 for the test in comment 1 of pr56385 (gfortran.dg/proc_ptr_comp_37.f90), but not in the original test. --- ../_clean/gcc/fortran/class.c2014-05-07 12:46:43.0 +0200 +++ gcc/fortran/class.c2014-07-17 18:01:17.0 +0200 @@ -833,7 +833,20 @@ finalize_component (gfc_expr *expr, gfc_ gfc_expr *e; gfc_ref *ref; - if (!comp_is_finalizable (comp)) +/* if (!comp_is_finalizable (comp)) */ + if (comp-ts.type != BT_DERIVED comp-ts.type != BT_CLASS + !comp-attr.allocatable) +return; + + if ((comp-ts.type == BT_DERIVED comp-attr.pointer) + || (comp-ts.type == BT_CLASS CLASS_DATA (comp) + CLASS_DATA (comp)-attr.pointer)) +return; + + if (comp-ts.type == BT_DERIVED !comp-attr.allocatable + (comp-ts.u.derived-f2k_derived == NULL + || comp-ts.u.derived-f2k_derived-finalizers == NULL) + !has_finalizer_component (comp-ts.u.derived)) return; e = gfc_copy_expr (expr); Note the ICEs reappear if I apply on top of the above the patch in comment 13 of pr59589. Could people familiar with finalization compare the tests in the above PRs and try to infer why comp-ts.u.derived-attr.alloc_comp changes the compiler behavior.
[Bug fortran/61819] [4.9/4.10 Regression] ICE in gfc_conv_descriptor_data_get
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61819 Dominique d'Humieres dominiq at lps dot ens.fr changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |DUPLICATE --- Comment #11 from Dominique d'Humieres dominiq at lps dot ens.fr --- See comment 4 of pr59765 for the origin of the problem. *** This bug has been marked as a duplicate of bug 59765 ***