public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all
@ 2021-10-22 16:06 burnus at gcc dot gnu.org
2021-10-22 17:52 ` [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all burnus at gcc dot gnu.org
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: burnus at gcc dot gnu.org @ 2021-10-22 16:06 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
Bug ID: 102900
Summary: ICE via gfc_class_data_get in alloc_comp_class_4.f03
with -fcheck=all
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: burnus at gcc dot gnu.org
Target Milestone: ---
Compiling the existing alloc_comp_class_4.f03 with -fcheck=all fails with:
alloc_comp_class_4.f03:91:29:
91 | call add_class_c(c_init2())
| 1
internal compiler error: Segmentation fault
0xfaae63 crash_signal
../../repos/gcc/gcc/toplev.c:322
0xa050a1 gfc_class_data_get(tree_node*)
../../repos/gcc/gcc/fortran/trans-expr.c:230
0xa0f97f gfc_conv_procedure_call(gfc_se*, gfc_symbol*, gfc_actual_arglist*,
gfc_expr*, vec<tree_node*, va_gc, vl_embed>*)
../../repos/gcc/gcc/fortran/trans-expr.c:7211
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
@ 2021-10-22 17:52 ` burnus at gcc dot gnu.org
2021-10-23 17:26 ` dominiq at lps dot ens.fr
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu.org @ 2021-10-22 17:52 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
Tobias Burnus <burnus at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|ICE via gfc_class_data_get |ICE via gfc_class_data_get
|in alloc_comp_class_4.f03 |with alloc_comp_class_4.f03
|with -fcheck=all |or proc_ptr_52.f90 using
| |-fcheck=all
--- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> ---
Similar but slightly different ICE for proc_ptr_52.f90 with -fcheck=all:
65 | y = apply (f, x) ! Fixed by first chunk in patch
| 1
internal compiler error: tree check: expected record_type or union_type or
qual_union_type, have function_type in gfc_class_data_get, at
fortran/trans-expr.c:232
0x7c1370 tree_check_failed(tree_node const*, char const*, int, char const*,
...)
../../repos/gcc/gcc/tree.c:8689
0x662539 tree_check3(tree_node*, char const*, int, char const*, tree_code,
tree_code, tree_code)
../../repos/gcc/gcc/tree.h:3473
0x662539 gfc_class_data_get(tree_node*)
../../repos/gcc/gcc/fortran/trans-expr.c:232
0xa0f97f gfc_conv_procedure_call(gfc_se*, gfc_symbol*, gfc_actual_arglist*,
gfc_expr*, vec<tree_node*, va_gc, vl_embed>*)
../../repos/gcc/gcc/fortran/trans-expr.c:7211
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
2021-10-22 17:52 ` [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all burnus at gcc dot gnu.org
@ 2021-10-23 17:26 ` dominiq at lps dot ens.fr
2021-10-25 9:04 ` marxin at gcc dot gnu.org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: dominiq at lps dot ens.fr @ 2021-10-23 17:26 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
Dominique d'Humieres <dominiq at lps dot ens.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2021-10-23
Ever confirmed|0 |1
--- Comment #2 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
Th error for gfc_class_data_get and alloc_comp_class_4.f03 is:
../../work/gcc/fortran/trans-expr.c:230:7: runtime error: member access within
null pointer of type 'union tree_node'
For the ICE is
internal compiler error: tree check: expected record_type or union_type or
qual_union_type, have function_type in gfc_class_data_get, at
fortran/trans-expr.c:232
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
2021-10-22 17:52 ` [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all burnus at gcc dot gnu.org
2021-10-23 17:26 ` dominiq at lps dot ens.fr
@ 2021-10-25 9:04 ` marxin at gcc dot gnu.org
2021-10-25 9:56 ` anlauf at gcc dot gnu.org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-10-25 9:04 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |anlauf at gcc dot gnu.org,
| |marxin at gcc dot gnu.org
--- Comment #3 from Martin Liška <marxin at gcc dot gnu.org> ---
Btw. started with r11-7661-gc2d7c39fcb8a3cb6.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
` (2 preceding siblings ...)
2021-10-25 9:04 ` marxin at gcc dot gnu.org
@ 2021-10-25 9:56 ` anlauf at gcc dot gnu.org
2021-10-25 21:05 ` anlauf at gcc dot gnu.org
2022-09-24 19:45 ` anlauf at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: anlauf at gcc dot gnu.org @ 2021-10-25 9:56 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
--- Comment #4 from anlauf at gcc dot gnu.org ---
The ICE is resolved by Jose's patch to PR100136, which was just accepted.
It would also need to get backported to 11-branch.
However, a runtime error will remain:
At line 91 of file gcc/testsuite/gfortran.dg/alloc_comp_class_4.f03
Fortran runtime error: Allocatable actual argument 'c_init2' is not allocated
Error termination. Backtrace:
#0 0x40114b in test_pr58586
at gcc/testsuite/gfortran.dg/alloc_comp_class_4.f03:91
#1 0x40114b in main
at gcc/testsuite/gfortran.dg/alloc_comp_class_4.f03:79
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
` (3 preceding siblings ...)
2021-10-25 9:56 ` anlauf at gcc dot gnu.org
@ 2021-10-25 21:05 ` anlauf at gcc dot gnu.org
2022-09-24 19:45 ` anlauf at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: anlauf at gcc dot gnu.org @ 2021-10-25 21:05 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
--- Comment #5 from anlauf at gcc dot gnu.org ---
(In reply to anlauf from comment #4)
> The ICE is resolved by Jose's patch to PR100136, which was just accepted.
... but not for proc_ptr_52.f90 with -fcheck=pointer
I've stared at the logic and the mail exchange regarding fixing PR99112,
but haven't understood yet what's wrong.
That's something Paul would likely fix hands down...
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
` (4 preceding siblings ...)
2021-10-25 21:05 ` anlauf at gcc dot gnu.org
@ 2022-09-24 19:45 ` anlauf at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: anlauf at gcc dot gnu.org @ 2022-09-24 19:45 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102900
--- Comment #6 from anlauf at gcc dot gnu.org ---
(In reply to anlauf from comment #5)
> (In reply to anlauf from comment #4)
> > The ICE is resolved by Jose's patch to PR100136, which was just accepted.
Update: with current mainline (PR100136 now fixed), the runtime failure of
alloc_comp_class_4.f03 with -fcheck=all is due to a missing allocate in
function c_init2. Adding
allocate (c_init2)
resolves this. This testcase is thus incompatible with -fcheck=pointer.
> ... but not for proc_ptr_52.f90 with -fcheck=pointer
This one remains.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2022-09-24 19:45 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-22 16:06 [Bug fortran/102900] New: ICE via gfc_class_data_get in alloc_comp_class_4.f03 with -fcheck=all burnus at gcc dot gnu.org
2021-10-22 17:52 ` [Bug fortran/102900] ICE via gfc_class_data_get with alloc_comp_class_4.f03 or proc_ptr_52.f90 using -fcheck=all burnus at gcc dot gnu.org
2021-10-23 17:26 ` dominiq at lps dot ens.fr
2021-10-25 9:04 ` marxin at gcc dot gnu.org
2021-10-25 9:56 ` anlauf at gcc dot gnu.org
2021-10-25 21:05 ` anlauf at gcc dot gnu.org
2022-09-24 19:45 ` 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).