public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/84868] [9/10/11/12 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
@ 2021-05-14 9:50 ` jakub at gcc dot gnu.org
2021-06-01 8:10 ` rguenth at gcc dot gnu.org
` (9 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2021-05-14 9:50 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|8.5 |9.4
--- Comment #9 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 8 branch is being closed.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [9/10/11/12 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
2021-05-14 9:50 ` [Bug fortran/84868] [9/10/11/12 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208 jakub at gcc dot gnu.org
@ 2021-06-01 8:10 ` rguenth at gcc dot gnu.org
2022-05-27 9:38 ` [Bug fortran/84868] [10/11/12/13 " rguenth at gcc dot gnu.org
` (8 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2021-06-01 8:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|9.4 |9.5
--- Comment #10 from Richard Biener <rguenth at gcc dot gnu.org> ---
GCC 9.4 is being released, retargeting bugs to GCC 9.5.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [10/11/12/13 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
2021-05-14 9:50 ` [Bug fortran/84868] [9/10/11/12 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208 jakub at gcc dot gnu.org
2021-06-01 8:10 ` rguenth at gcc dot gnu.org
@ 2022-05-27 9:38 ` rguenth at gcc dot gnu.org
2022-06-28 10:34 ` jakub at gcc dot gnu.org
` (7 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-05-27 9:38 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|9.5 |10.4
--- Comment #11 from Richard Biener <rguenth at gcc dot gnu.org> ---
GCC 9 branch is being closed
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [10/11/12/13 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2022-05-27 9:38 ` [Bug fortran/84868] [10/11/12/13 " rguenth at gcc dot gnu.org
@ 2022-06-28 10:34 ` jakub at gcc dot gnu.org
2023-07-07 10:33 ` [Bug fortran/84868] [11/12/13/14 " rguenth at gcc dot gnu.org
` (6 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-06-28 10:34 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|10.4 |10.5
--- Comment #12 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 10.4 is being released, retargeting bugs to GCC 10.5.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [11/12/13/14 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2022-06-28 10:34 ` jakub at gcc dot gnu.org
@ 2023-07-07 10:33 ` rguenth at gcc dot gnu.org
2024-04-26 9:51 ` pault at gcc dot gnu.org
` (5 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-07-07 10:33 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|10.5 |11.5
--- Comment #13 from Richard Biener <rguenth at gcc dot gnu.org> ---
GCC 10 branch is being closed.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [11/12/13/14 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2023-07-07 10:33 ` [Bug fortran/84868] [11/12/13/14 " rguenth at gcc dot gnu.org
@ 2024-04-26 9:51 ` pault at gcc dot gnu.org
2024-07-12 9:43 ` [Bug fortran/84868] [11/12/13/14/15 " pault at gcc dot gnu.org
` (4 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pault at gcc dot gnu.org @ 2024-04-26 9:51 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Paul Thomas <pault at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |pault at gcc dot gnu.org
CC| |pault at gcc dot gnu.org
--- Comment #14 from Paul Thomas <pault at gcc dot gnu.org> ---
(In reply to G. Steinmetz from comment #0)
> Changed between 20161204 and 20161211 :
>
>
> $ cat z1.f90
> module m
> character(:), allocatable :: c
> contains
> function f(n) result(z)
> character, parameter :: c(3) = ['x', 'y', 'z']
> integer, intent(in) :: n
> character(len_trim(c(n))) :: z
> z = c(n)
> end
> end
> program p
> use m
> print *, f(2)
> end
>
>
> $ gfortran-7-20161204 -c z1.f90
> $
> $ gfortran-8-20180311 -c z1.f90
> z1.f90:13:0:
>
> print *, f(2)
>
> internal compiler error: in gfc_conv_descriptor_offset, at
> fortran/trans-array.c:208
> 0x74e222 gfc_conv_descriptor_offset
> ../../gcc/fortran/trans-array.c:208
> 0x75349c gfc_conv_descriptor_offset_get(tree_node*)
> ../../gcc/fortran/trans-array.c:220
> 0x75349c gfc_conv_array_offset(tree_node*)
> ../../gcc/fortran/trans-array.c:2967
> 0x75349c gfc_conv_array_ref(gfc_se*, gfc_array_ref*, gfc_expr*, locus*)
> ../../gcc/fortran/trans-array.c:3575
> 0x780ddd gfc_conv_variable
> ../../gcc/fortran/trans-expr.c:2737
> 0x77db02 gfc_conv_expr(gfc_se*, gfc_expr*)
> ../../gcc/fortran/trans-expr.c:7926
> 0x78a98c gfc_conv_intrinsic_function_args
> ../../gcc/fortran/trans-intrinsic.c:223
> 0x79dc3d gfc_conv_intrinsic_len_trim
> ../../gcc/fortran/trans-intrinsic.c:6248
> 0x79dc3d gfc_conv_intrinsic_function(gfc_se*, gfc_expr*)
> ../../gcc/fortran/trans-intrinsic.c:9134
> 0x77d545 gfc_conv_function_expr
> ../../gcc/fortran/trans-expr.c:6784
> 0x77dae2 gfc_conv_expr(gfc_se*, gfc_expr*)
> ../../gcc/fortran/trans-expr.c:7918
> 0x77fa8a gfc_apply_interface_mapping(gfc_interface_mapping*, gfc_se*,
> gfc_expr*)
> ../../gcc/fortran/trans-expr.c:4409
> 0x77b6f7 gfc_conv_procedure_call(gfc_se*, gfc_symbol*, gfc_actual_arglist*,
> gfc_expr*, vec<tree_node*, va_gc, vl_embed>*)
> ../../gcc/fortran/trans-expr.c:5970
> 0x77d59c gfc_conv_function_expr
> ../../gcc/fortran/trans-expr.c:6808
> 0x77dae2 gfc_conv_expr(gfc_se*, gfc_expr*)
> ../../gcc/fortran/trans-expr.c:7918
> 0x7843aa gfc_conv_expr_reference(gfc_se*, gfc_expr*)
> ../../gcc/fortran/trans-expr.c:8018
> 0x7a3d56 gfc_trans_transfer(gfc_code*)
> ../../gcc/fortran/trans-io.c:2585
> 0x749ec7 trans_code
> ../../gcc/fortran/trans.c:2044
> 0x7a1807 build_dt
> ../../gcc/fortran/trans-io.c:2027
> 0x749ee7 trans_code
> ../../gcc/fortran/trans.c:2016
This, I believe, was commit 345bd7ebbb38f0e1d5acf33ab3f680111cfa7871 where
LEN_TRIM was introduced to interface mapping on 2016-12-09 for pr44265.
Removing the chunk concerned does not fix the problem.
I have stared at this for ages. For reasons that I cannot see, the use
associated version of 'c' is being used, so the interface mapping has failed.
I will come back to this.
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [11/12/13/14/15 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2024-04-26 9:51 ` pault at gcc dot gnu.org
@ 2024-07-12 9:43 ` pault at gcc dot gnu.org
2024-07-12 11:47 ` pault at gcc dot gnu.org
` (3 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pault at gcc dot gnu.org @ 2024-07-12 9:43 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
--- Comment #15 from Paul Thomas <pault at gcc dot gnu.org> ---
(In reply to Harald Anlauf from comment #6)
> (In reply to Harald Anlauf from comment #5)
> > With the following patch len_trim is accepted in a specification expression:
>
> Just forget that.
Indeed:
NAG Fortran Compiler Release 7.1(Hanzomon) Build 7133
Error: orig.f90, line 7: C is not permitted in a specification expression
[pault@pc30 pr84868]$ ifort o*.f90 ;./a.out
orig.f90(5): error #6219: This variable, used in a specification expression,
must be a dummy argument, a COMMON block object, or an object accessible
through host or use association. [C]
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [11/12/13/14/15 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2024-07-12 9:43 ` [Bug fortran/84868] [11/12/13/14/15 " pault at gcc dot gnu.org
@ 2024-07-12 11:47 ` pault at gcc dot gnu.org
2024-07-13 7:20 ` pault at gcc dot gnu.org
` (2 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pault at gcc dot gnu.org @ 2024-07-12 11:47 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
--- Comment #16 from Paul Thomas <pault at gcc dot gnu.org> ---
Created attachment 58641
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=58641&action=edit
Fix for this PR
The only way that I have found to fix this is to simplify the len_trim
expression. In doing so, another parameter has to be created for which I have
taken a leaf out of the unique_name mechanism. Unfortunately, two such
parameters are created (parsing specification expression and then resolution),
the first one of which is unused. I don't see any easy way to eliminate it.
I came across another bug in testing variants, which is also fixed. Regtests
OK.
I'll think further about doubling up on the parameter before submitting.
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [11/12/13/14/15 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (7 preceding siblings ...)
2024-07-12 11:47 ` pault at gcc dot gnu.org
@ 2024-07-13 7:20 ` pault at gcc dot gnu.org
2024-07-16 14:56 ` cvs-commit at gcc dot gnu.org
2024-07-19 13:02 ` [Bug fortran/84868] [12/13/14 " rguenth at gcc dot gnu.org
10 siblings, 0 replies; 11+ messages in thread
From: pault at gcc dot gnu.org @ 2024-07-13 7:20 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
--- Comment #17 from Paul Thomas <pault at gcc dot gnu.org> ---
(In reply to Paul Thomas from comment #16)
> Created attachment 58641 [details]
> Fix for this PR
>
> The only way that I have found to fix this is to simplify the len_trim
> expression. In doing so, another parameter has to be created for which I
> have taken a leaf out of the unique_name mechanism. Unfortunately, two such
> parameters are created (parsing specification expression and then
> resolution), the first one of which is unused. I don't see any easy way to
> eliminate it.
>
> I came across another bug in testing variants, which is also fixed. Regtests
> OK.
>
> I'll think further about doubling up on the parameter before submitting.
>
> Paul
I have figured out how to eliminate the duplicate parameter. I will be
submitting to the list very soon :-)
Cheers
Paul
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [11/12/13/14/15 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (8 preceding siblings ...)
2024-07-13 7:20 ` pault at gcc dot gnu.org
@ 2024-07-16 14:56 ` cvs-commit at gcc dot gnu.org
2024-07-19 13:02 ` [Bug fortran/84868] [12/13/14 " rguenth at gcc dot gnu.org
10 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-07-16 14:56 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
--- Comment #18 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Paul Thomas <pault@gcc.gnu.org>:
https://gcc.gnu.org/g:9f966b6a8ff0244dd6f8bf36d876799d5f9bbaee
commit r15-2072-g9f966b6a8ff0244dd6f8bf36d876799d5f9bbaee
Author: Paul Thomas <pault@gcc.gnu.org>
Date: Tue Jul 16 15:56:44 2024 +0100
Fortran: Simplify len_trim with array ref and fix mapping bug[PR84868].
2024-07-16 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran
PR fortran/84868
* simplify.cc (gfc_simplify_len_trim): If the argument is an
element of a parameter array, simplify all the elements and
build a new parameter array to hold the result, after checking
that it doesn't already exist.
* trans-expr.cc (gfc_get_interface_mapping_array) if a string
length is available, use it for the typespec.
(gfc_add_interface_mapping): Supply the se string length.
gcc/testsuite/
PR fortran/84868
* gfortran.dg/pr84868.f90: New test.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug fortran/84868] [12/13/14 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
` (9 preceding siblings ...)
2024-07-16 14:56 ` cvs-commit at gcc dot gnu.org
@ 2024-07-19 13:02 ` rguenth at gcc dot gnu.org
10 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-07-19 13:02 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84868
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|11.5 |12.5
--- Comment #19 from Richard Biener <rguenth at gcc dot gnu.org> ---
GCC 11 branch is being closed.
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2024-07-19 13:02 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-84868-4@http.gcc.gnu.org/bugzilla/>
2021-05-14 9:50 ` [Bug fortran/84868] [9/10/11/12 Regression] ICE in gfc_conv_descriptor_offset, at fortran/trans-array.c:208 jakub at gcc dot gnu.org
2021-06-01 8:10 ` rguenth at gcc dot gnu.org
2022-05-27 9:38 ` [Bug fortran/84868] [10/11/12/13 " rguenth at gcc dot gnu.org
2022-06-28 10:34 ` jakub at gcc dot gnu.org
2023-07-07 10:33 ` [Bug fortran/84868] [11/12/13/14 " rguenth at gcc dot gnu.org
2024-04-26 9:51 ` pault at gcc dot gnu.org
2024-07-12 9:43 ` [Bug fortran/84868] [11/12/13/14/15 " pault at gcc dot gnu.org
2024-07-12 11:47 ` pault at gcc dot gnu.org
2024-07-13 7:20 ` pault at gcc dot gnu.org
2024-07-16 14:56 ` cvs-commit at gcc dot gnu.org
2024-07-19 13:02 ` [Bug fortran/84868] [12/13/14 " rguenth at gcc dot gnu.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).