public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/107219] New: ICE in reduce_unary, at fortran/arith.cc:1290
@ 2022-10-11 17:00 gscfq@t-online.de
2022-10-11 18:52 ` [Bug fortran/107219] " anlauf at gcc dot gnu.org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: gscfq@t-online.de @ 2022-10-11 17:00 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107219
Bug ID: 107219
Summary: ICE in reduce_unary, at fortran/arith.cc:1290
Product: gcc
Version: 13.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: gscfq@t-online.de
Target Milestone: ---
Affects versions down to at least r5 :
(in addition to pr93483_c2_first_print)
$ cat z1.f90
program p
print *, -[real :: [(1)]]
print *, +[real :: [-(1)]]
print *, -[real :: [[(1)]]]
end
$ gfortran-13-20221009 -c z1.f90
f951: internal compiler error: Segmentation fault
0xf3feef crash_signal
../../gcc/toplev.cc:314
0x7becaf reduce_unary
../../gcc/fortran/arith.cc:1290
0x7bec7f reduce_unary
../../gcc/fortran/arith.cc:1277
0x7bec7f reduce_unary
../../gcc/fortran/arith.cc:1277
0x7bf408 eval_intrinsic
../../gcc/fortran/arith.cc:1652
0x832374 match_level_2
../../gcc/fortran/matchexp.cc:490
0x832392 match_level_3
../../gcc/fortran/matchexp.cc:551
0x832484 match_level_4
../../gcc/fortran/matchexp.cc:599
0x832484 match_and_operand
../../gcc/fortran/matchexp.cc:693
0x832672 match_or_operand
../../gcc/fortran/matchexp.cc:722
0x832742 match_equiv_operand
../../gcc/fortran/matchexp.cc:765
0x832814 match_level_5
../../gcc/fortran/matchexp.cc:811
0x831be1 gfc_match_expr(gfc_expr**)
../../gcc/fortran/matchexp.cc:870
0x8192d9 match_io_element
../../gcc/fortran/io.cc:3668
0x81bc0a match_io_list
../../gcc/fortran/io.cc:3716
0x81c00e match_io
../../gcc/fortran/io.cc:4394
0x81fb0a gfc_match_print()
../../gcc/fortran/io.cc:4450
0x851e41 match_word
../../gcc/fortran/parse.cc:67
0x857aa3 decode_statement
../../gcc/fortran/parse.cc:539
0x857eda next_free
../../gcc/fortran/parse.cc:1402
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/107219] ICE in reduce_unary, at fortran/arith.cc:1290
2022-10-11 17:00 [Bug fortran/107219] New: ICE in reduce_unary, at fortran/arith.cc:1290 gscfq@t-online.de
@ 2022-10-11 18:52 ` anlauf at gcc dot gnu.org
2022-10-17 17:27 ` cvs-commit at gcc dot gnu.org
2022-10-17 17:36 ` anlauf at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: anlauf at gcc dot gnu.org @ 2022-10-11 18:52 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107219
anlauf at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=93483
Status|UNCONFIRMED |NEW
Last reconfirmed| |2022-10-11
Ever confirmed|0 |1
CC| |anlauf at gcc dot gnu.org
--- Comment #1 from anlauf at gcc dot gnu.org ---
Confirmed.
The following example from pr93483 has the same issue:
print *, +[ real :: (1) ]
end
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/107219] ICE in reduce_unary, at fortran/arith.cc:1290
2022-10-11 17:00 [Bug fortran/107219] New: ICE in reduce_unary, at fortran/arith.cc:1290 gscfq@t-online.de
2022-10-11 18:52 ` [Bug fortran/107219] " anlauf at gcc dot gnu.org
@ 2022-10-17 17:27 ` cvs-commit at gcc dot gnu.org
2022-10-17 17:36 ` anlauf at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-10-17 17:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107219
--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Harald Anlauf <anlauf@gcc.gnu.org>:
https://gcc.gnu.org/g:d45af5c2eb1ba1e48449d8f3c5b4e3994a956f92
commit r13-3340-gd45af5c2eb1ba1e48449d8f3c5b4e3994a956f92
Author: Harald Anlauf <anlauf@gmx.de>
Date: Sat Oct 15 21:56:56 2022 +0200
Fortran: handle bad array ctors with typespec [PR93483, PR107216, PR107219]
gcc/fortran/ChangeLog:
PR fortran/93483
PR fortran/107216
PR fortran/107219
* arith.cc (reduce_unary): Handled expressions are EXP_CONSTANT and
EXPR_ARRAY. Do not attempt to reduce otherwise.
(reduce_binary_ac): Likewise.
(reduce_binary_ca): Likewise.
(reduce_binary_aa): Moved check for EXP_CONSTANT and EXPR_ARRAY
from here ...
(reduce_binary): ... to here.
(eval_intrinsic): Catch failed reductions.
* gfortran.h (GFC_INTRINSIC_OPS): New enum ARITH_NOT_REDUCED to
keep
track of expressions that were not reduced by the arithmetic
evaluation
code.
gcc/testsuite/ChangeLog:
PR fortran/93483
PR fortran/107216
PR fortran/107219
* gfortran.dg/array_constructor_56.f90: New test.
* gfortran.dg/array_constructor_57.f90: New test.
Co-authored-by: Mikael Morin <mikael@gcc.gnu.org>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/107219] ICE in reduce_unary, at fortran/arith.cc:1290
2022-10-11 17:00 [Bug fortran/107219] New: ICE in reduce_unary, at fortran/arith.cc:1290 gscfq@t-online.de
2022-10-11 18:52 ` [Bug fortran/107219] " anlauf at gcc dot gnu.org
2022-10-17 17:27 ` cvs-commit at gcc dot gnu.org
@ 2022-10-17 17:36 ` anlauf at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: anlauf at gcc dot gnu.org @ 2022-10-17 17:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107219
anlauf at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |13.0
Status|NEW |RESOLVED
Resolution|--- |FIXED
--- Comment #3 from anlauf at gcc dot gnu.org ---
Fixed for gcc-13. Closing.
Thanks for your insistence!
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-10-17 17:36 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-11 17:00 [Bug fortran/107219] New: ICE in reduce_unary, at fortran/arith.cc:1290 gscfq@t-online.de
2022-10-11 18:52 ` [Bug fortran/107219] " anlauf at gcc dot gnu.org
2022-10-17 17:27 ` cvs-commit at gcc dot gnu.org
2022-10-17 17:36 ` anlauf 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).