public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed
@ 2022-10-12 7:27 zhendong.su at inf dot ethz.ch
2022-10-12 8:04 ` [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933 marxin at gcc dot gnu.org
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: zhendong.su at inf dot ethz.ch @ 2022-10-12 7:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
Bug ID: 107229
Summary: ICE at -O1 and -Os with "-ftree-vectorize":
verify_gimple failed
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: zhendong.su at inf dot ethz.ch
Target Milestone: ---
This appears to be a very recent regression as it doesn't seem to fail with the
build from Compiler Explorer.
[541] % gcctk -v
Using built-in specs.
COLLECT_GCC=gcctk
COLLECT_LTO_WRAPPER=/local/suz-local/software/local/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/13.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-trunk/configure --disable-bootstrap
--enable-checking=yes --prefix=/local/suz-local/software/local/gcc-trunk
--enable-sanitizers --enable-languages=c,c++ --disable-werror --enable-multilib
--with-system-zlib
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 13.0.0 20221012 (experimental) [master r13-3246-g1c0670c62fc] (GCC)
[542] %
[542] % gcctk -O1 small.c; ./a.out
[543] %
[543] % gcctk -O1 -ftree-vectorize small.c
small.c: In function ‘main’:
small.c:9:5: error: invalid position or size operand to ‘bit_field_ref’
9 | int main() {
| ^~~~
_ifc__17 = BIT_FIELD_REF <_ifc__16, 21, 0xffffffffffffffffffffffffffffffc0>;
during GIMPLE pass: ifcvt
small.c:9:5: internal compiler error: verify_gimple failed
0xf3b99a verify_gimple_in_cfg(function*, bool)
../../gcc-trunk/gcc/tree-cfg.cc:5649
0xdf9d17 execute_function_todo
../../gcc-trunk/gcc/passes.cc:2091
0xdfa2bb execute_todo
../../gcc-trunk/gcc/passes.cc:2145
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
[544] %
[544] % cat small.c
int a, c;
struct {
long d;
int : 8;
int : 27;
int e : 21;
} f;
void g(int b) { a = a & 1; }
int main() {
while (c)
g(f.e);
return 0;
}
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
@ 2022-10-12 8:04 ` marxin at gcc dot gnu.org
2022-10-12 9:26 ` avieira at gcc dot gnu.org
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: marxin at gcc dot gnu.org @ 2022-10-12 8:04 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Last reconfirmed| |2022-10-12
Status|UNCONFIRMED |NEW
Version|unknown |13.0
CC| |andre.simoesdiasvieira@arm.
| |com, marxin at gcc dot gnu.org
Target Milestone|--- |13.0
Summary|ICE at -O1 and -Os with |[13 Regression] ICE at -O1
|"-ftree-vectorize": |and -Os with
|verify_gimple failed |"-ftree-vectorize":
| |verify_gimple failed since
| |r13-3219-g25413fdb2ac24933
--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r13-3219-g25413fdb2ac24933.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
2022-10-12 8:04 ` [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933 marxin at gcc dot gnu.org
@ 2022-10-12 9:26 ` avieira at gcc dot gnu.org
2022-10-12 16:23 ` law at gcc dot gnu.org
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: avieira at gcc dot gnu.org @ 2022-10-12 9:26 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
--- Comment #2 from avieira at gcc dot gnu.org ---
So it seems I should have taken DECL_FIELD_OFFSET into account when computing
the bitpos in get_bitfield_rep (tree-if-conv.cc).
I am testing a patch for this whilst I also look at the failures in PR107226
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
2022-10-12 8:04 ` [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933 marxin at gcc dot gnu.org
2022-10-12 9:26 ` avieira at gcc dot gnu.org
@ 2022-10-12 16:23 ` law at gcc dot gnu.org
2022-10-13 9:15 ` marxin at gcc dot gnu.org
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: law at gcc dot gnu.org @ 2022-10-12 16:23 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
Jeffrey A. Law <law at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |law at gcc dot gnu.org
--- Comment #3 from Jeffrey A. Law <law at gcc dot gnu.org> ---
Note that we're seeing linux kernel build failures that may have the same
underlying problem:
./cc1 -O2 -mabi=64 main.i -quiet -I./
../drivers/base/power/main.c: In function ‘__device_suspend’:
../drivers/base/power/main.c:1606:12: error: invalid ‘PHI’ argument
_142
during GIMPLE pass: ifcvt
../drivers/base/power/main.c:1606:12: internal compiler error: tree check:
expected class ‘type’, have ‘exceptional’ (error_mark) in
useless_type_conversion_p, at gimple-expr.cc:87
0x176e2f4 tree_class_check_failed(tree_node const*, tree_code_class, char
const*, int, char const*)
/home/jlaw/test/gcc/gcc/tree.cc:8877
0xa058bb tree_class_check(tree_node*, tree_code_class, char const*, int, char
const*)
/home/jlaw/test/gcc/gcc/tree.h:3649
0xe9369a useless_type_conversion_p(tree_node*, tree_node*)
/home/jlaw/test/gcc/gcc/gimple-expr.cc:87
0x13a4bd3 verify_gimple_phi
/home/jlaw/test/gcc/gcc/tree-cfg.cc:5201
0x13a57dd verify_gimple_in_cfg(function*, bool)
/home/jlaw/test/gcc/gcc/tree-cfg.cc:5530
I'll monitor this bug and re-test the kernel build once Andre has a potential
patch. If it turns out to be a distinct problem, then I'll open a new bug.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
` (2 preceding siblings ...)
2022-10-12 16:23 ` law at gcc dot gnu.org
@ 2022-10-13 9:15 ` marxin at gcc dot gnu.org
2022-10-13 11:11 ` cvs-commit at gcc dot gnu.org
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: marxin at gcc dot gnu.org @ 2022-10-13 9:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> ---
*** Bug 107246 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
` (3 preceding siblings ...)
2022-10-13 9:15 ` marxin at gcc dot gnu.org
@ 2022-10-13 11:11 ` cvs-commit at gcc dot gnu.org
2022-10-14 7:19 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-10-13 11:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Andre Simoes Dias Vieira
<avieira@gcc.gnu.org>:
https://gcc.gnu.org/g:9f0d4adabe2035886a1aa8d2ca990a90de000613
commit r13-3270-g9f0d4adabe2035886a1aa8d2ca990a90de000613
Author: Andre Vieira <andre.simoesdiasvieira@arm.com>
Date: Thu Oct 13 12:09:38 2022 +0100
ifcvt: Fix bitpos calculation in bitfield lowering [PR107229]
The bitposition calculation for the bitfield lowering in loop if conversion
was
not taking DECL_FIELD_OFFSET into account, which meant that it would result
in
wrong bitpositions for bitfields that did not end up having representations
starting at the beginning of the struct.
gcc/ChangeLog:
PR tree-optimization/107229
* tree-if-conv.cc (get_bitfield_rep): Fix bitposition calculation.
gcc/testsuite/ChangeLog:
* gcc.dg/vect/pr107229-1.c: New test.
* gcc.dg/vect/pr107229-2.c: New test.
* gcc.dg/vect/pr107229-3.c: New test.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
` (4 preceding siblings ...)
2022-10-13 11:11 ` cvs-commit at gcc dot gnu.org
@ 2022-10-14 7:19 ` rguenth at gcc dot gnu.org
2022-10-14 7:20 ` rguenth at gcc dot gnu.org
2022-10-14 7:27 ` rguenth at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-10-14 7:19 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Priority|P3 |P1
Status|NEW |RESOLVED
--- Comment #6 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed I assume.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
` (5 preceding siblings ...)
2022-10-14 7:19 ` rguenth at gcc dot gnu.org
@ 2022-10-14 7:20 ` rguenth at gcc dot gnu.org
2022-10-14 7:27 ` rguenth at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-10-14 7:20 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ro at gcc dot gnu.org
--- Comment #7 from Richard Biener <rguenth at gcc dot gnu.org> ---
*** Bug 107232 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
` (6 preceding siblings ...)
2022-10-14 7:20 ` rguenth at gcc dot gnu.org
@ 2022-10-14 7:27 ` rguenth at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-10-14 7:27 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107229
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dcb314 at hotmail dot com
--- Comment #8 from Richard Biener <rguenth at gcc dot gnu.org> ---
*** Bug 107244 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2022-10-14 7:27 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-12 7:27 [Bug tree-optimization/107229] New: ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed zhendong.su at inf dot ethz.ch
2022-10-12 8:04 ` [Bug tree-optimization/107229] [13 Regression] ICE at -O1 and -Os with "-ftree-vectorize": verify_gimple failed since r13-3219-g25413fdb2ac24933 marxin at gcc dot gnu.org
2022-10-12 9:26 ` avieira at gcc dot gnu.org
2022-10-12 16:23 ` law at gcc dot gnu.org
2022-10-13 9:15 ` marxin at gcc dot gnu.org
2022-10-13 11:11 ` cvs-commit at gcc dot gnu.org
2022-10-14 7:19 ` rguenth at gcc dot gnu.org
2022-10-14 7:20 ` rguenth at gcc dot gnu.org
2022-10-14 7:27 ` 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).