public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/94600] New: Ignored volatile specifier on loop unrolling and bitfield misoptimization
@ 2020-04-14 23:27 hp at gcc dot gnu.org
  2020-04-14 23:32 ` [Bug middle-end/94600] " hp at gcc dot gnu.org
                   ` (13 more replies)
  0 siblings, 14 replies; 15+ messages in thread
From: hp at gcc dot gnu.org @ 2020-04-14 23:27 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94600

            Bug ID: 94600
           Summary: Ignored volatile specifier on loop unrolling and
                    bitfield misoptimization
           Product: gcc
           Version: 10.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: hp at gcc dot gnu.org
  Target Milestone: ---
              Host: x86_64-unknown-linux-gnu
            Target: arm-eabi, cris-elf, aarch64-linux

Created attachment 48275
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48275&action=edit
test-case in need of decoration for the gcc test-suite. Compile e.g. at -O2 or
-Os.

Observe the unwieldy code in function foo compiled at -O2 or -Os for any of the
listed targets (and likely many more, except curiously not x86_64 and i386).

Compare this to the compiled bar; nice as expected.

Note in particular the reads in the generated code from the LHS specified as
volatile and which is only stored into in the source code.  Note also the
smaller-than-struct-sized stores. The latter may be target-dependent but the
reads should not happen anywhere.

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2021-12-21  2:46 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-14 23:27 [Bug middle-end/94600] New: Ignored volatile specifier on loop unrolling and bitfield misoptimization hp at gcc dot gnu.org
2020-04-14 23:32 ` [Bug middle-end/94600] " hp at gcc dot gnu.org
2020-04-14 23:36 ` hp at gcc dot gnu.org
2020-04-15  6:46 ` rguenth at gcc dot gnu.org
2020-04-15  7:05 ` rguenth at gcc dot gnu.org
2020-04-15  7:06 ` rguenth at gcc dot gnu.org
2020-04-15  7:07 ` rguenth at gcc dot gnu.org
2020-04-15 22:33 ` joseph at codesourcery dot com
2020-04-15 22:45 ` hp at gcc dot gnu.org
2020-07-13  6:09 ` cvs-commit at gcc dot gnu.org
2020-07-13  6:30 ` cvs-commit at gcc dot gnu.org
2020-08-13  3:13 ` cvs-commit at gcc dot gnu.org
2020-12-04 19:29 ` cvs-commit at gcc dot gnu.org
2020-12-04 19:37 ` cvs-commit at gcc dot gnu.org
2021-12-21  2:46 ` hp 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).