public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "m dot reszat at kostal dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c/23623] New: volatile keyword changes bitfield access size from 32bit to 8bit Date: Mon, 29 Aug 2005 14:11:00 -0000 [thread overview] Message-ID: <20050829140226.23623.m.reszat@kostal.com> (raw) struct { unsigned int b : 1; } bf1; volatile struct { unsigned int b : 1; } bf2; void test(void) { bf1.b = 1; bf2.b = 1; } Access to bf1.b is correctly done as 32-bits (lwz/stw opcodes), bf2.b is accessed as 8-bits (lbz/stb opcodes). GCC3.4.3 shows the same behaviour, can't go back any further. The same happens when the bitfield itself is made volatile, not the whole struct. -- Summary: volatile keyword changes bitfield access size from 32bit to 8bit Product: gcc Version: 4.0.1 Status: UNCONFIRMED Severity: normal Priority: P2 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: m dot reszat at kostal dot com CC: gcc-bugs at gcc dot gnu dot org GCC host triplet: i686-pc-cygwin GCC target triplet: powerpc-elf-eabispe http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23623
next reply other threads:[~2005-08-29 14:08 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2005-08-29 14:11 m dot reszat at kostal dot com [this message] 2005-08-29 15:39 ` [Bug middle-end/23623] " pinskia at gcc dot gnu dot org 2005-08-29 16:21 ` pinskia at gcc dot gnu dot org 2005-08-29 21:27 ` falk at debian dot org 2005-08-30 7:59 ` m dot reszat at kostal dot com 2005-08-30 12:44 ` falk at debian dot org 2005-08-30 12:51 ` rearnsha at gcc dot gnu dot org 2005-08-30 13:42 ` m dot reszat at kostal dot com 2005-08-30 14:06 ` rearnsha at gcc dot gnu dot org 2005-09-08 15:12 ` m dot reszat at kostal dot com
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=20050829140226.23623.m.reszat@kostal.com \ --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).