public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/108782] New: [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359
@ 2023-02-14 3:25 asolokha at gmx dot com
2023-02-14 7:09 ` [Bug tree-optimization/108782] " rguenth at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: asolokha at gmx dot com @ 2023-02-14 3:25 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108782
Bug ID: 108782
Summary: [13 Regression] ICE in add_phi_arg, at
tree-phinodes.cc:359
Product: gcc
Version: 13.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: asolokha at gmx dot com
Target Milestone: ---
gcc 13.0.1 20230212 snapshot (g:06ca0c9abb260266b688e2c2154c72214bb47076) ICEs
when compiling the following testcase w/ -O1 -fno-tree-copy-prop:
int m;
__attribute__ ((simd)) int
foo (void)
{
int a, b = 0;
m = a = 1;
while (a != 0)
{
b = m;
m = 2;
++a;
}
return b;
}
% gcc-13 -O1 -fno-tree-copy-prop -w -c nkivh61j.c
during GIMPLE pass: vect
nkivh61j.c: In function 'foo.simdclone.0':
nkivh61j.c:4:1: internal compiler error: in add_phi_arg, at
tree-phinodes.cc:359
4 | foo (void)
| ^~~
0x764623 add_phi_arg(gphi*, tree_node*, edge_def*, unsigned int)
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-phinodes.cc:359
0x118e3a6 vectorizable_recurr(_loop_vec_info*, _stmt_vec_info*, gimple**,
_slp_tree*, vec<stmt_info_for_cost, va_heap, vl_ptr>*)
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vect-loop.cc:8489
0x1f73bf8 vect_transform_stmt(vec_info*, _stmt_vec_info*,
gimple_stmt_iterator*, _slp_tree*, _slp_instance*)
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vect-stmts.cc:11467
0x119fff3 vect_transform_loop(_loop_vec_info*, gimple*)
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vect-loop.cc:10890
0x11dfde0 vect_transform_loops
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vectorizer.cc:1007
0x11e041e try_vectorize_loop_1
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vectorizer.cc:1153
0x11e041e try_vectorize_loop
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vectorizer.cc:1183
0x11e07d4 execute
/var/tmp/portage/sys-devel/gcc-13.0.1_p20230212/work/gcc-13-20230212/gcc/tree-vectorizer.cc:1299
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/108782] [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359
2023-02-14 3:25 [Bug tree-optimization/108782] New: [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359 asolokha at gmx dot com
@ 2023-02-14 7:09 ` rguenth at gcc dot gnu.org
2023-02-14 10:08 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-02-14 7:09 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108782
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |13.0
Status|UNCONFIRMED |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot gnu.org
Ever confirmed|0 |1
Last reconfirmed| |2023-02-14
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
I will have a look.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/108782] [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359
2023-02-14 3:25 [Bug tree-optimization/108782] New: [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359 asolokha at gmx dot com
2023-02-14 7:09 ` [Bug tree-optimization/108782] " rguenth at gcc dot gnu.org
@ 2023-02-14 10:08 ` rguenth at gcc dot gnu.org
2023-02-14 11:50 ` cvs-commit at gcc dot gnu.org
2023-02-14 11:50 ` rguenth at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-02-14 10:08 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108782
--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
We're applying outer loop vectorization but the nested cycle isn't vectorizable
because we run into
if (!flow_bb_inside_loop_p (loop, gimple_bb (use_stmt)))
{
if (dump_enabled_p ())
dump_printf_loc (MSG_MISSED_OPTIMIZATION, vect_location,
"intermediate value used outside loop.\n");
return NULL;
}
but I think that's premature. Still vectorizing it as first order recurrence
isn't possible either.
Testing a patch.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/108782] [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359
2023-02-14 3:25 [Bug tree-optimization/108782] New: [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359 asolokha at gmx dot com
2023-02-14 7:09 ` [Bug tree-optimization/108782] " rguenth at gcc dot gnu.org
2023-02-14 10:08 ` rguenth at gcc dot gnu.org
@ 2023-02-14 11:50 ` cvs-commit at gcc dot gnu.org
2023-02-14 11:50 ` rguenth at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-02-14 11:50 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108782
--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <rguenth@gcc.gnu.org>:
https://gcc.gnu.org/g:994224236e0231807681b62e880d3c2772c69521
commit r13-5983-g994224236e0231807681b62e880d3c2772c69521
Author: Richard Biener <rguenther@suse.de>
Date: Tue Feb 14 11:10:56 2023 +0100
tree-optimization/108782 - nested first order recurrence vectorization
First order recurrence vectorization isn't possible for nested
loops.
PR tree-optimization/108782
* tree-vect-loop.cc (vect_phi_first_order_recurrence_p):
Make sure we're not vectorizing an inner loop.
* gcc.dg/torture/pr108782.c: New testcase.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug tree-optimization/108782] [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359
2023-02-14 3:25 [Bug tree-optimization/108782] New: [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359 asolokha at gmx dot com
` (2 preceding siblings ...)
2023-02-14 11:50 ` cvs-commit at gcc dot gnu.org
@ 2023-02-14 11:50 ` rguenth at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-02-14 11:50 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108782
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-02-14 11:50 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-14 3:25 [Bug tree-optimization/108782] New: [13 Regression] ICE in add_phi_arg, at tree-phinodes.cc:359 asolokha at gmx dot com
2023-02-14 7:09 ` [Bug tree-optimization/108782] " rguenth at gcc dot gnu.org
2023-02-14 10:08 ` rguenth at gcc dot gnu.org
2023-02-14 11:50 ` cvs-commit at gcc dot gnu.org
2023-02-14 11:50 ` 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).