* [Bug c/93537] gcc 9.2 takes a Segmentation Violation when attached file is compiled
[not found] <bug-93537-4@http.gcc.gnu.org/bugzilla/>
@ 2024-04-09 5:59 ` pinskia at gcc dot gnu.org
2024-04-09 6:03 ` [Bug c/93537] [11/12 Regression] " pinskia at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2024-04-09 5:59 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93537
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |needs-bisection
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
I can't figure what fixed it ... But it seems to have been fixed in GCC 10.1.0.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/93537] [11/12 Regression] gcc 9.2 takes a Segmentation Violation when attached file is compiled
[not found] <bug-93537-4@http.gcc.gnu.org/bugzilla/>
2024-04-09 5:59 ` [Bug c/93537] gcc 9.2 takes a Segmentation Violation when attached file is compiled pinskia at gcc dot gnu.org
@ 2024-04-09 6:03 ` pinskia at gcc dot gnu.org
2024-04-09 6:16 ` pinskia at gcc dot gnu.org
` (2 subsequent siblings)
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2024-04-09 6:03 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93537
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|gcc 9.2 takes a |[11/12 Regression] gcc 9.2
|Segmentation Violation when |takes a Segmentation
|attached file is compiled |Violation when attached
| |file is compiled
Known to fail| |11.4.0, 12.1.0, 12.2.0,
| |9.1.0, 9.5.0
Keywords|needs-bisection |
Known to work|10.1.0 |8.1.0
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Actually it is still broken in GCC 12.1.0, 12.2.0 and 12.3.0 and 11.4.0. I
don't know why it was working in GCC 12.1.0. Seems to work in GCC 13.1.0 and
13.2.0 though ....
And on the trunk.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/93537] [11/12 Regression] gcc 9.2 takes a Segmentation Violation when attached file is compiled
[not found] <bug-93537-4@http.gcc.gnu.org/bugzilla/>
2024-04-09 5:59 ` [Bug c/93537] gcc 9.2 takes a Segmentation Violation when attached file is compiled pinskia at gcc dot gnu.org
2024-04-09 6:03 ` [Bug c/93537] [11/12 Regression] " pinskia at gcc dot gnu.org
@ 2024-04-09 6:16 ` pinskia at gcc dot gnu.org
2024-04-09 6:17 ` pinskia at gcc dot gnu.org
2024-06-12 11:20 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2024-04-09 6:16 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93537
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Created attachment 57909
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=57909&action=edit
Reduced testcase
This as reduced as I could get it for now.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/93537] [11/12 Regression] gcc 9.2 takes a Segmentation Violation when attached file is compiled
[not found] <bug-93537-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2024-04-09 6:16 ` pinskia at gcc dot gnu.org
@ 2024-04-09 6:17 ` pinskia at gcc dot gnu.org
2024-06-12 11:20 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2024-04-09 6:17 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93537
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-on-invalid-code,
| |ice-on-valid-code,
| |needs-bisection
Target Milestone|--- |11.5
--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Someone should debug this further. because I don't understand how it works in
GCC 10.x series but then fails in the same way again in GCC 11.x/12.x. and
started passing in GCC 13.x.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/93537] [11/12 Regression] gcc 9.2 takes a Segmentation Violation when attached file is compiled
[not found] <bug-93537-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2024-04-09 6:17 ` pinskia at gcc dot gnu.org
@ 2024-06-12 11:20 ` rguenth at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2024-06-12 11:20 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93537
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed|2020-02-01 00:00:00 |2024-6-12
Priority|P3 |P2
Known to work| |13.1.0, 8.4.0
--- Comment #6 from Richard Biener <rguenth at gcc dot gnu.org> ---
Re-confirmed on the 12 branch.
(gdb) up
#3 0x0000000000c5650e in pp_c_enumeration_constant (pp=0x3eef950,
e=<integer_cst 0x7ffff6a2b450>)
at /space/rguenther/src/gcc-12-branch/gcc/c-family/c-pretty-print.cc:1068
1068 if (tree_int_cst_equal (DECL_INITIAL (TREE_VALUE (value)), e))
(gdb) l
1063
1064 /* Find the name of this constant. */
1065 if ((pp->flags & pp_c_flag_gnu_v3) == 0)
1066 for (value = TYPE_VALUES (type); value != NULL_TREE;
1067 value = TREE_CHAIN (value))
1068 if (tree_int_cst_equal (DECL_INITIAL (TREE_VALUE (value)), e))
1069 break;
1070
1071 if (value != NULL_TREE)
1072 pp->id_expression (TREE_PURPOSE (value));
(gdb) p debug_tree (value)
<tree_list 0x7ffff6b44cd0
purpose <identifier_node 0x7ffff6b5f500 TS_HANDLE_EXTENSION
symbol <const_decl 0x7ffff6b71000 TS_HANDLE_EXTENSION type
<enumeral_type 0x7ffff6b70540 TSGenType_E>
VOID /tmp/t.c:2:28
align:1 warn_if_not_align:0 initial <integer_cst 0x7ffff6b59468
99>>>
value <integer_cst 0x7ffff6b59468 type <integer_type 0x7ffff6a275e8 int>
constant 99>>
I'd say we likely get the enumeral type wrong, we assume a CONST_DECL but
have
<enumeral_type 0x7ffff6b707e0 TSGenTypeE asm_written unsigned SI
size <integer_cst 0x7ffff6a0bf90 type <integer_type 0x7ffff6a270a8
bitsizetype> constant 32>
unit-size <integer_cst 0x7ffff6a0bfa8 type <integer_type 0x7ffff6a27000
sizetype> constant 4>
align:32 warn_if_not_align:0 symtab:-155847024 alias-set -1 canonical-type
0x7ffff6b70540 precision:32 min <integer_cst 0x7ffff6a0bfc0 0> max <integer_cst
0x7ffff6a0bf78 4294967295>
values <tree_list 0x7ffff6b44cd0
purpose <identifier_node 0x7ffff6b5f500 TS_HANDLE_EXTENSION symbol
<const_decl 0x7ffff6b71000 TS_HANDLE_EXTENSION>>
value <integer_cst 0x7ffff6b59468 constant 99>>
chain <type_decl 0x7ffff6a36688 D.1981>>
^ permalink raw reply [flat|nested] 5+ messages in thread