public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "anbu1024.me at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c/101437] New: [12 Regression] ICE: Segmentation fault signal terminated program cc1 Date: Tue, 13 Jul 2021 14:18:30 +0000 [thread overview] Message-ID: <bug-101437-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101437 Bug ID: 101437 Summary: [12 Regression] ICE: Segmentation fault signal terminated program cc1 Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: anbu1024.me at gmail dot com Target Milestone: --- $ cat test.c struct s { unsigned int : 1; }; inline static void foo(int x) { struct s this_struct = {.var = x}; *((volatile struct s *) 0x880000UL) = this_struct; } void bar() { foo(0); } -------------------------------- $ gcc-sp12 --version gcc (GCC) 12.0.0 20210711 (experimental) Copyright (C) 2021 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -------------------------------- $ gcc-sp12 test.c test.c: In function ‘foo’: test.c:9:28: error: ‘struct s’ has no member named ‘var’ 9 | struct s this_struct = {.var = x}; | ^~~ test.c:9:34: warning: excess elements in struct initializer 9 | struct s this_struct = {.var = x}; | ^ test.c:9:34: note: (near initialization for ‘this_struct’) gcc: internal compiler error: Segmentation fault signal terminated program cc1 Please submit a full bug report, with preprocessed source if appropriate. See <https://gcc.gnu.org/bugs/> for instructions. -------------------------------- $ gcc-sp11 --version gcc (GCC) 11.1.1 20210710 Copyright (C) 2021 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -------------------------------- $ gcc-sp11 test.c test.c: In function ‘foo’: test.c:9:28: error: ‘struct s’ has no member named ‘var’ 9 | struct s this_struct = {.var = x}; | ^~~ test.c:9:34: warning: excess elements in struct initializer 9 | struct s this_struct = {.var = x}; | ^ test.c:9:34: note: (near initialization for ‘this_struct’)
next reply other threads:[~2021-07-13 14:18 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-07-13 14:18 anbu1024.me at gmail dot com [this message] 2021-07-14 6:04 ` [Bug c/101437] " rguenth at gcc dot gnu.org 2021-07-14 10:33 ` jakub at gcc dot gnu.org 2021-07-14 10:38 ` jakub at gcc dot gnu.org 2021-07-14 11:05 ` jakub at gcc dot gnu.org 2021-07-14 11:06 ` jakub at gcc dot gnu.org 2021-07-14 11:45 ` jakub at gcc dot gnu.org 2021-07-14 18:36 ` [Bug middle-end/101437] " pinskia at gcc dot gnu.org 2021-07-15 8:17 ` cvs-commit at gcc dot gnu.org 2021-07-15 8:25 ` jakub at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-101437-4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).