public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/99825] New: ICE in vect_build_combine_node
@ 2021-03-30 8:20 asolokha at gmx dot com
2021-03-30 9:58 ` [Bug target/99825] [11 Regression] " jakub at gcc dot gnu.org
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: asolokha at gmx dot com @ 2021-03-30 8:20 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
Bug ID: 99825
Summary: ICE in vect_build_combine_node
Product: gcc
Version: 11.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: asolokha at gmx dot com
Target Milestone: ---
Target: aarch64-linux-gnu
gfortran-11.0.1-alpha20210328 snapshot
(g:499fa254ae8c9752d8c2cf3130b13ffddfd83546) ICEs when compiling the following
testcase, reduced from gcc/testsuite/gfortran.dg/inline_matmul_11.f90, w/
-march=armv8.3-a -O3:
program main
complex, dimension(3, 2) :: a
complex, dimension(2, 4) :: b
complex, dimension(3, 4) :: c, res1
data a /0, (-5., -7.), (11., -13.), 0, 0, 0/
data b /0, 0, 0, 0, 0, 0, 0, 0/
data res1 /0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0/
c = matmul(a, conjg(b))
if (any(res1 /= c)) stop 2
end program main
% aarch64-linux-gnu-gfortran-11.0.1 -march=armv8.3-a -O3 -c xfxklbt7.f90
during GIMPLE pass: vect
xfxklbt7.f90:12:16:
12 | end program main
| ^
internal compiler error: in quick_push, at vec.h:1021
0x7c477e vec<std::pair<unsigned int, unsigned int>, va_heap,
vl_embed>::quick_push(std::pair<unsigned int, unsigned int> const&)
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/vec.h:1021
0x7c489a vec<std::pair<unsigned int, unsigned int>, va_heap,
vl_embed>::quick_push(std::pair<unsigned int, unsigned int> const&)
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp-patterns.c:907
0x7c489a vec<std::pair<unsigned int, unsigned int>, va_heap,
vl_ptr>::quick_push(std::pair<unsigned int, unsigned int> const&)
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/vec.h:1875
0x7c489a vect_build_combine_node
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp-patterns.c:891
0x123f945 complex_mul_pattern::build(vec_info*)
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp-patterns.c:1068
0x1232418 vect_match_slp_patterns_2
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp.c:2430
0x12323c4 vect_match_slp_patterns_2
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp.c:2422
0x12323c4 vect_match_slp_patterns_2
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp.c:2422
0x12366b7 vect_match_slp_patterns
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp.c:2458
0x12366b7 vect_analyze_slp(vec_info*, unsigned int)
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-slp.c:2901
0x1213157 vect_analyze_loop_2
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-loop.c:2316
0x1214eb3 vect_analyze_loop(loop*, vec_info_shared*)
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vect-loop.c:2985
0x1245aa7 try_vectorize_loop_1
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vectorizer.c:1009
0x1246540 vectorize_loops()
/var/tmp/portage/cross-aarch64-linux-gnu/gcc-11.0.1_alpha20210328/work/gcc-11-20210328/gcc/tree-vectorizer.c:1243
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/99825] [11 Regression] ICE in vect_build_combine_node
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
@ 2021-03-30 9:58 ` jakub at gcc dot gnu.org
2021-03-30 10:06 ` jakub at gcc dot gnu.org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2021-03-30 9:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|ICE in |[11 Regression] ICE in
|vect_build_combine_node |vect_build_combine_node
Target Milestone|--- |11.0
Ever confirmed|0 |1
CC| |jakub at gcc dot gnu.org
Status|UNCONFIRMED |NEW
Last reconfirmed| |2021-03-30
Priority|P3 |P1
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Started with r11-6734-gad2603433853129e847cade5e269c6a5f889a020
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/99825] [11 Regression] ICE in vect_build_combine_node
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
2021-03-30 9:58 ` [Bug target/99825] [11 Regression] " jakub at gcc dot gnu.org
@ 2021-03-30 10:06 ` jakub at gcc dot gnu.org
2021-03-30 10:15 ` tnfchris at gcc dot gnu.org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2021-03-30 10:06 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tnfchris at gcc dot gnu.org
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
887 perm.create (SLP_TREE_LANES (rep));
888
889 for (unsigned x = 0; x < SLP_TREE_LANES (rep); x+=2)
890 {
891 perm.quick_push (std::make_pair (0, x));
892 perm.quick_push (std::make_pair (1, x+1));
893 }
that was added in r11-6693-ge09173d84dabd186ad2463f47350c1bcabfeab8f
can't really work, it allocates just SLP_TREE_LANES (resp) elements,
but can quick_push one more elements - when SLP_TREE_LANES is odd (in this
testcase 3). So, either some caller needs to ensure SLP_TREE_LANES is even or
this function isn't called, or it needs to be changed to handle even odd
numbers.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug target/99825] [11 Regression] ICE in vect_build_combine_node
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
2021-03-30 9:58 ` [Bug target/99825] [11 Regression] " jakub at gcc dot gnu.org
2021-03-30 10:06 ` jakub at gcc dot gnu.org
@ 2021-03-30 10:15 ` tnfchris at gcc dot gnu.org
2021-03-30 10:46 ` [Bug tree-optimization/99825] " tnfchris at gcc dot gnu.org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2021-03-30 10:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
Tamar Christina <tnfchris at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |tnfchris at gcc dot gnu.org
--- Comment #3 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #2)
> 887 perm.create (SLP_TREE_LANES (rep));
> 888
> 889 for (unsigned x = 0; x < SLP_TREE_LANES (rep); x+=2)
> 890 {
> 891 perm.quick_push (std::make_pair (0, x));
> 892 perm.quick_push (std::make_pair (1, x+1));
> 893 }
>
> that was added in r11-6693-ge09173d84dabd186ad2463f47350c1bcabfeab8f
> can't really work, it allocates just SLP_TREE_LANES (resp) elements,
> but can quick_push one more elements - when SLP_TREE_LANES is odd (in this
> testcase 3). So, either some caller needs to ensure SLP_TREE_LANES is even
> or this function isn't called, or it needs to be changed to handle even odd
> numbers.
It can't work on odd lanes since the operation needs to update both a real and
imaginary component. So this should have been rejected much earlier.
Testing a patch.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/99825] [11 Regression] ICE in vect_build_combine_node
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
` (2 preceding siblings ...)
2021-03-30 10:15 ` tnfchris at gcc dot gnu.org
@ 2021-03-30 10:46 ` tnfchris at gcc dot gnu.org
2021-03-30 13:17 ` cvs-commit at gcc dot gnu.org
2021-03-30 13:17 ` tnfchris at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2021-03-30 10:46 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
Tamar Christina <tnfchris at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|target |tree-optimization
Status|NEW |ASSIGNED
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/99825] [11 Regression] ICE in vect_build_combine_node
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
` (3 preceding siblings ...)
2021-03-30 10:46 ` [Bug tree-optimization/99825] " tnfchris at gcc dot gnu.org
@ 2021-03-30 13:17 ` cvs-commit at gcc dot gnu.org
2021-03-30 13:17 ` tnfchris at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-03-30 13:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Tamar Christina <tnfchris@gcc.gnu.org>:
https://gcc.gnu.org/g:9c68e2abe294a48385224cd7617eca0720144b5c
commit r11-7909-g9c68e2abe294a48385224cd7617eca0720144b5c
Author: Tamar Christina <tamar.christina@arm.com>
Date: Tue Mar 30 14:16:03 2021 +0100
slp: reject non-multiple of 2 laned SLP trees (PR99825)
TWO_OPERANDS allows any order or number of combinations of + and -
operations
but the pattern matcher only supports pairs of operations.
This patch has the pattern matcher for complex numbers reject SLP trees
where
the lanes are not a multiple of 2.
gcc/ChangeLog:
PR tree-optimization/99825
* tree-vect-slp-patterns.c (vect_check_evenodd_blend):
Reject non-mult 2 lanes.
gcc/testsuite/ChangeLog:
PR tree-optimization/99825
* gfortran.dg/vect/pr99825.f90: New test.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug tree-optimization/99825] [11 Regression] ICE in vect_build_combine_node
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
` (4 preceding siblings ...)
2021-03-30 13:17 ` cvs-commit at gcc dot gnu.org
@ 2021-03-30 13:17 ` tnfchris at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: tnfchris at gcc dot gnu.org @ 2021-03-30 13:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99825
Tamar Christina <tnfchris at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #5 from Tamar Christina <tnfchris at gcc dot gnu.org> ---
Fixed.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2021-03-30 13:17 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-30 8:20 [Bug target/99825] New: ICE in vect_build_combine_node asolokha at gmx dot com
2021-03-30 9:58 ` [Bug target/99825] [11 Regression] " jakub at gcc dot gnu.org
2021-03-30 10:06 ` jakub at gcc dot gnu.org
2021-03-30 10:15 ` tnfchris at gcc dot gnu.org
2021-03-30 10:46 ` [Bug tree-optimization/99825] " tnfchris at gcc dot gnu.org
2021-03-30 13:17 ` cvs-commit at gcc dot gnu.org
2021-03-30 13:17 ` tnfchris 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).