public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "kungfujesus06 at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c/108498] ppc64 big endian generates uninitialized reads with -fstore-merging Date: Mon, 23 Jan 2023 15:18:28 +0000 [thread overview] Message-ID: <bug-108498-4-K6IDIw8rYy@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-108498-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108498 --- Comment #1 from Adam Stylinski <kungfujesus06 at gmail dot com> --- I also should note this affects GCC 11.3, as well. The code being generated via this optimization, while marginally shorter, seems to be rather suboptimal in general. Here's what clang's emitting for the same sequence: 0000000000000930 <.emit_test>: 930: 3c a0 02 00 lis r5,512 934: 38 80 00 01 li r4,1 938: 88 e3 00 08 lbz r7,8(r3) 93c: 60 a5 ff 03 ori r5,r5,65283 940: 38 c0 02 01 li r6,513 944: f8 83 00 0c std r4,12(r3) 948: 38 80 00 02 li r4,2 94c: 78 a5 01 8a rldic r5,r5,32,6 950: f8 83 00 14 std r4,20(r3) 954: 38 80 00 00 li r4,0 958: 78 c6 d0 02 rotldi r6,r6,58 95c: 64 a5 00 01 oris r5,r5,1 960: f8 83 00 34 std r4,52(r3) 964: 38 80 00 1c li r4,28 968: 60 a5 02 03 ori r5,r5,515 96c: f8 c3 00 24 std r6,36(r3) 970: 54 e6 07 fe clrlwi r6,r7,31 974: 50 c4 07 b4 rlwimi r4,r6,0,30,26 978: f8 a3 00 00 std r5,0(r3) 97c: 3c a0 00 01 lis r5,1 980: 98 83 00 08 stb r4,8(r3) 984: 60 a4 02 03 ori r4,r5,515 988: 78 84 c5 c8 rldic r4,r4,24,23 98c: f8 83 00 3c std r4,60(r3) 990: 4e 80 00 20 blr This bug is affecting the mesa project, so at least fixing this to emitting correct code (if a little suboptimal) would go a long way.
next prev parent reply other threads:[~2023-01-23 15:18 UTC|newest] Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-01-23 14:18 [Bug c/108498] New: " kungfujesus06 at gmail dot com 2023-01-23 15:18 ` kungfujesus06 at gmail dot com [this message] 2023-01-23 15:20 ` [Bug middle-end/108498] " pinskia at gcc dot gnu.org 2023-01-23 15:22 ` kungfujesus06 at gmail dot com 2023-01-23 15:34 ` kungfujesus06 at gmail dot com 2023-01-23 15:38 ` rguenth at gcc dot gnu.org 2023-01-23 15:48 ` kungfujesus06 at gmail dot com 2023-01-23 15:51 ` kungfujesus06 at gmail dot com 2023-01-23 15:54 ` kungfujesus06 at gmail dot com 2023-01-23 17:39 ` pinskia at gcc dot gnu.org 2023-01-23 17:40 ` pinskia at gcc dot gnu.org 2023-01-23 17:42 ` kungfujesus06 at gmail dot com 2023-01-23 17:45 ` pinskia at gcc dot gnu.org 2023-01-23 17:51 ` [Bug tree-optimization/108498] " pinskia at gcc dot gnu.org 2023-01-23 17:51 ` kungfujesus06 at gmail dot com 2023-01-23 18:18 ` kungfujesus06 at gmail dot com 2023-01-23 19:04 ` jakub at gcc dot gnu.org 2023-01-24 12:20 ` [Bug tree-optimization/108498] [11/12/13 Regression] " jakub at gcc dot gnu.org 2023-01-24 12:55 ` jakub at gcc dot gnu.org 2023-01-24 15:35 ` jakub at gcc dot gnu.org 2023-01-24 16:09 ` jakub at gcc dot gnu.org 2023-01-24 16:48 ` ebotcazou at gcc dot gnu.org 2023-01-24 17:10 ` jakub at gcc dot gnu.org 2023-01-24 17:33 ` ebotcazou at gcc dot gnu.org 2023-01-24 17:46 ` jakub at gcc dot gnu.org 2023-01-25 9:51 ` cvs-commit at gcc dot gnu.org 2023-01-25 10:35 ` [Bug tree-optimization/108498] [11/12 " jakub at gcc dot gnu.org 2023-02-10 17:46 ` cvs-commit at gcc dot gnu.org 2023-02-10 18:00 ` [Bug tree-optimization/108498] [11 " jakub at gcc dot gnu.org 2023-05-02 20:13 ` cvs-commit at gcc dot gnu.org 2023-05-03 10:35 ` 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-108498-4-K6IDIw8rYy@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).