public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "kikairoya at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c/50521] -fstrict-volatile-bitfields is not strict Date: Sat, 29 Oct 2011 06:50:00 -0000 [thread overview] Message-ID: <bug-50521-4-bSlYsxOsDg@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-50521-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50521 --- Comment #13 from Tomohiro Kashiwada <kikairoya at gmail dot com> 2011-10-29 06:50:11 UTC --- (In reply to comment #12) > Regarding the double load. In a statement like a = b, both a & be should be > individually accessed even if they refer to the same storage. So > bitfield.bits.a = bitfield.bits.c should load the bitfield variable twice, once > for reading the rvalue and once for masking the lvalue assignment. > > See 7.1.7.5 second and third paragraph and the note just after. Is that means a statement a = b; always should be treat as if tmp = b; a = tmp; two individual statements? > Regarding STRICT_ALIGNMENT, not strictly needed on ARM i think. Smaller > accesses than the base type is acceptable, as long as it's aligned to the > matching access size (8/16/32/64 bit) and on ARMv7 unaligned access is allowed, > but at a performance penalty. And this change is technically unrelated to > strict-volatile-bitfields even if there is overlap. I think STRICT_ALIGNMENT is not only for ARM, but also MIPS, SH and others. I'll create new ticket later about STRICT_ALIGNMENT.
next prev parent reply other threads:[~2011-10-29 6:50 UTC|newest] Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top 2011-09-26 7:18 [Bug c/50521] New: " kikairoya at gmail dot com 2011-09-26 11:43 ` [Bug c/50521] " rguenth at gcc dot gnu.org 2011-09-26 12:08 ` kikairoya at gmail dot com 2011-09-27 8:22 ` kikairoya at gmail dot com 2011-10-20 1:54 ` kikairoya at gmail dot com 2011-10-27 23:23 ` henrik at henriknordstrom dot net 2011-10-28 1:33 ` kikairoya at gmail dot com 2011-10-28 2:00 ` henrik at henriknordstrom dot net 2011-10-28 3:59 ` kikairoya at gmail dot com 2011-10-28 7:34 ` henrik at henriknordstrom dot net 2011-10-28 8:13 ` kikairoya at gmail dot com 2011-10-28 8:15 ` kikairoya at gmail dot com 2011-10-28 17:46 ` henrik at henriknordstrom dot net 2011-10-29 6:50 ` kikairoya at gmail dot com [this message] 2011-10-29 10:46 ` henrik at henriknordstrom dot net 2011-10-29 14:37 ` kikairoya at gmail 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=bug-50521-4-bSlYsxOsDg@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).