public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/97551] New: ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone"
@ 2020-10-23 15:43 suochenyao at 163 dot com
2020-10-26 9:54 ` [Bug ipa/97551] " marxin at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: suochenyao at 163 dot com @ 2020-10-23 15:43 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97551
Bug ID: 97551
Summary: ICE: verify_cgraph_node failed with "-O2
-fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop
-fno-tree-fre -fipa-cp-clone"
Product: gcc
Version: 11.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: suochenyao at 163 dot com
Target Milestone: ---
*******************************************************************************
OS and Platform:
CentOS Linux release 7.8.2003 (Core), x86_64 GNU/Linux
*******************************************************************************
Program:
int a=0, b=0;
char c=0;
long d=0;
long (e)(int f, int g) { return f && g || g > 0 && f || f <= 0 && g && f && g <
0 ? : g; }
void h(int f) {
for (; c;) {
e(7, d);
for (; a;)
b = !f;
}
}
void i() { h(0); }
int main() { return 0; }
*******************************************************************************
gcc version:
$ gcc -v
Using built-in specs.
COLLECT_GCC=/home/suocy/bin/gcc-dev/bin/gcc
COLLECT_LTO_WRAPPER=/home/suocy/bin/gcc-dev/libexec/gcc/x86_64-pc-linux-gnu/11.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../configure --prefix=/home/suocy/bin/gcc-dev/
--disable-multilib --enable-languages=c,c++
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 11.0.0 20201023 (experimental) (GCC)
git version: 43868df37b0e1fa19c32175b41dd7dc1e7c515fd
*******************************************************************************
Command Lines:
$ gcc -Wall -Wextra -fno-strict-aliasing -fwrapv -O2 -fno-toplevel-reorder
-fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone a.c
a.c: In function ‘e’:
a.c:4:35: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]
4 | long (e)(int f, int g) { return f && g || g > 0 && f || f <= 0 && g &&
f && g < 0 ? : g; }
| ~~^~~~
a.c:4:74: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]
4 | long (e)(int f, int g) { return f && g || g > 0 && f || f <= 0 && g &&
f && g < 0 ? : g; }
|
~~~~~~~~~~~~~~~~~^~~~~~~~
a.c:4:86: warning: the omitted middle operand in ‘?:’ will always be ‘true’,
suggest explicit middle operand [-Wparentheses]
4 | long (e)(int f, int g) { return f && g || g > 0 && f || f <= 0 && g &&
f && g < 0 ? : g; }
|
^
a.c: In function ‘i’:
a.c:12:12: error: edge points to wrong declaration:
12 | void i() { h(0); }
| ^~~~
<function_decl 0x7f042463f300 e.constprop.isra
type <function_type 0x7f04246400a8
type <void_type 0x7f04244edf18 void VOID
align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x7f04244edf18
pointer_to_this <pointer_type 0x7f04244f5000>>
QI
size <integer_cst 0x7f04244d4dc8 constant 8>
unit-size <integer_cst 0x7f04244d4de0 constant 1>
align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x7f04246400a8
arg-types <tree_list 0x7f0424633a28 value <integer_type 0x7f04244ed5e8
int>
chain <tree_list 0x7f04244e98c0 value <void_type 0x7f04244edf18
void>>>
pointer_to_this <pointer_type 0x7f0424640498>>
readonly addressable used nothrow static decl_5 QI a.c:4:7 align:8
warn_if_not_align:0 context <translation_unit_decl 0x7f04244e1c30 a.c>>
Instead of: <function_decl 0x7f0424605600 e
type <function_type 0x7f042460d2a0
type <integer_type 0x7f04244ed738 long int public DI
size <integer_cst 0x7f04244d4cd8 constant 64>
unit-size <integer_cst 0x7f04244d4cf0 constant 8>
align:64 warn_if_not_align:0 symtab:0 alias-set 2 canonical-type
0x7f04244ed738 precision:64 min <integer_cst 0x7f04244d4f60
-9223372036854775808> max <integer_cst 0x7f04244d4f78 9223372036854775807>
pointer_to_this <pointer_type 0x7f04244fd150>>
QI
size <integer_cst 0x7f04244d4dc8 constant 8>
unit-size <integer_cst 0x7f04244d4de0 constant 1>
align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x7f042460d2a0
arg-types <tree_list 0x7f0424601c80 value <integer_type 0x7f04244ed5e8
int>
chain <tree_list 0x7f0424601c58 value <integer_type 0x7f04244ed5e8
int>
chain <tree_list 0x7f04244e98c0 value <void_type 0x7f04244edf18
void>>>>
pointer_to_this <pointer_type 0x7f042460d3f0>>
readonly addressable asm_written used nothrow public static decl_5 QI
a.c:4:7 align:8 warn_if_not_align:0 context <translation_unit_decl
0x7f04244e1c30 a.c> initial <error_mark 0x7f04244d4cc0>
result <result_decl 0x7f04244e1a50 D.1937 type <integer_type 0x7f04244ed738
long int>
ignored regdecl DI a.c:4:7 size <integer_cst 0x7f04244d4cd8 64>
unit-size <integer_cst 0x7f04244d4cf0 8>
align:64 warn_if_not_align:0 context <function_decl 0x7f0424605600 e>
(reg:DI 0 ax [orig:89 <retval> ] [89])>
(mem:QI (symbol_ref:DI ("e") [flags 0x3] <function_decl 0x7f0424605600 e>)
[0 S1 A8]) chain <function_decl 0x7f0424605800 h>>
h.constprop.0/8 (h.constprop) @0x7f042462c540
Type: function definition analyzed
Visibility: no_reorder artificial
References: d/3 (read) b/1 (write) a/0 (read) c/2 (read)
Referring:
Function h.constprop/8 is inline copy in i/6
Availability: local
Function flags: count:1073741824 (estimated locally) body local nonfreeing_fn
Called by: i/6 (inlined) (1073741824 (estimated locally),1.00 per call)
Calls: e.constprop.0.isra.0/10 (8687547438 (estimated locally),8.09 per call)
during IPA pass: inline
a.c:12:12: internal compiler error: verify_cgraph_node failed
0x9939e0 cgraph_node::verify_node()
../../gcc/cgraph.c:3800
0x9869d4 symtab_node::verify()
../../gcc/symtab.c:1318
0xe490cb expand_call_inline
../../gcc/tree-inline.c:4833
0xe4b9f9 gimple_expand_calls_inline
../../gcc/tree-inline.c:5266
0xe4b9f9 optimize_inline_calls(tree_node*)
../../gcc/tree-inline.c:5439
0xbb1a1b inline_transform(cgraph_node*)
../../gcc/ipa-inline-transform.c:749
0xceaf45 execute_one_ipa_transform_pass
../../gcc/passes.c:2240
0xceaf45 execute_all_ipa_transforms(bool)
../../gcc/passes.c:2287
0x99905d cgraph_node::expand()
../../gcc/cgraphunit.c:2303
0x99a39a output_in_order
../../gcc/cgraphunit.c:2621
0x99a39a symbol_table::compile()
../../gcc/cgraphunit.c:2839
0x99c9f7 symbol_table::compile()
../../gcc/cgraphunit.c:2755
0x99c9f7 symbol_table::finalize_compilation_unit()
../../gcc/cgraphunit.c:3023
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/97551] ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone"
2020-10-23 15:43 [Bug c/97551] New: ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone" suochenyao at 163 dot com
@ 2020-10-26 9:54 ` marxin at gcc dot gnu.org
2021-04-27 11:39 ` jakub at gcc dot gnu.org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: marxin at gcc dot gnu.org @ 2020-10-26 9:54 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97551
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |11.0
Known to fail| |11.0
Priority|P3 |P1
Ever confirmed|0 |1
Known to work| |10.2.0
Status|UNCONFIRMED |NEW
Last reconfirmed| |2020-10-26
--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r11-4267-g0e590b68fa374365.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/97551] ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone"
2020-10-23 15:43 [Bug c/97551] New: ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone" suochenyao at 163 dot com
2020-10-26 9:54 ` [Bug ipa/97551] " marxin at gcc dot gnu.org
@ 2021-04-27 11:39 ` jakub at gcc dot gnu.org
2021-07-28 7:04 ` rguenth at gcc dot gnu.org
2023-05-14 21:55 ` [Bug ipa/97551] [11 Regression] " pinskia at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: jakub at gcc dot gnu.org @ 2021-04-27 11:39 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97551
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|11.0 |11.2
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 11.1 has been released, retargeting bugs to GCC 11.2.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/97551] ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone"
2020-10-23 15:43 [Bug c/97551] New: ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone" suochenyao at 163 dot com
2020-10-26 9:54 ` [Bug ipa/97551] " marxin at gcc dot gnu.org
2021-04-27 11:39 ` jakub at gcc dot gnu.org
@ 2021-07-28 7:04 ` rguenth at gcc dot gnu.org
2023-05-14 21:55 ` [Bug ipa/97551] [11 Regression] " pinskia at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2021-07-28 7:04 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97551
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|11.2 |---
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/97551] [11 Regression] ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone"
2020-10-23 15:43 [Bug c/97551] New: ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone" suochenyao at 163 dot com
` (2 preceding siblings ...)
2021-07-28 7:04 ` rguenth at gcc dot gnu.org
@ 2023-05-14 21:55 ` pinskia at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2023-05-14 21:55 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97551
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|ICE: verify_cgraph_node |[11 Regression] ICE:
|failed with "-O2 |verify_cgraph_node failed
|-fno-toplevel-reorder |with "-O2
|-fno-tree-dce |-fno-toplevel-reorder
|-fno-tree-forwprop |-fno-tree-dce
|-fno-tree-fre |-fno-tree-forwprop
|-fipa-cp-clone" |-fno-tree-fre
| |-fipa-cp-clone"
Resolution|--- |FIXED
Status|NEW |RESOLVED
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=97576
Target Milestone|--- |11.0
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Been fixed for a few years now even in GCC 11.
So closing as such.
I suspect it was fixed by the same patch as PR 97576.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-05-14 21:55 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-23 15:43 [Bug c/97551] New: ICE: verify_cgraph_node failed with "-O2 -fno-toplevel-reorder -fno-tree-dce -fno-tree-forwprop -fno-tree-fre -fipa-cp-clone" suochenyao at 163 dot com
2020-10-26 9:54 ` [Bug ipa/97551] " marxin at gcc dot gnu.org
2021-04-27 11:39 ` jakub at gcc dot gnu.org
2021-07-28 7:04 ` rguenth at gcc dot gnu.org
2023-05-14 21:55 ` [Bug ipa/97551] [11 Regression] " pinskia 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).