public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "luoxhu at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/106069] [12/13 Regression] wrong code with -O -fno-tree-forwprop -maltivec on ppc64le Date: Tue, 26 Jul 2022 06:28:47 +0000 [thread overview] Message-ID: <bug-106069-4-F0ow7K3Oxo@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-106069-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106069 --- Comment #16 from luoxhu at gcc dot gnu.org --- The attached files are all built with -mcpu=power8 and the case also fails on P8LE. Also I verified the code produces expected output on P8BE. ('Aborted' is caused by BE returns 0x41 instead of 0x98 for LE.) P8LE &P9LE: luoxhu@gcc135 build $ ./q.bad B0: 0, 0,0,0 Aborted P8BE: luoxhu@gcc203:~/workspace/build$ ./q.bad B0: 41fcef98, 91648e8b,7dca18c6,61707865 Aborted P8BE seems generates better code with the patch: luoxhu@gcc203:~/workspace/build$ diff q.good.S q.bad.S -U5 --- q.good.S 2022-07-26 09:19:32.487216946 +0300 +++ q.bad.S 2022-07-26 09:15:58.006770996 +0300 @@ -1,6 +1,7 @@ .file "q.C" + .machine power8 .section ".text" .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "B0: %x, %x,%x,%x\n" @@ -24,19 +25,17 @@ .cfi_def_cfa_offset 128 .cfi_offset 65, 16 .cfi_offset 30, -16 .cfi_offset 31, -8 mr %r30,%r3 - vmrghw %v2,%v2,%v4 - vmrghw %v5,%v3,%v5 - vmrghw %v5,%v2,%v5 - vspltw %v0,%v5,3 + vspltw %v0,%v5,0 mfvsrwz %r7,%vs32 - vspltw %v0,%v5,2 + vspltw %v0,%v4,0 mfvsrwz %r6,%vs32 - mfvsrwz %r5,%vs37 - vspltw %v0,%v5,0 + vspltw %v0,%v3,0 + mfvsrwz %r5,%vs32 + vspltw %v0,%v2,0 mfvsrwz %r31,%vs32 rldicl %r7,%r7,0,32 rldicl %r6,%r6,0,32 rldicl %r5,%r5,0,32 rldicl %r4,%r31,0,32 @@ -169,6 +168,6 @@ .set .LANCHOR1,. + 0 .type res, @object .size res, 1 res: .zero 1 - .ident "GCC: (Debian 9.5.0-1) 9.5.0" + .ident "GCC: (GNU) 13.0.0 20220726 (experimental)"
next prev parent reply other threads:[~2022-07-26 6:28 UTC|newest] Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-06-23 23:13 [Bug target/106069] New: " mpolacek at gcc dot gnu.org 2022-06-23 23:15 ` [Bug target/106069] [12/13 Regression] " mpolacek at gcc dot gnu.org 2022-06-23 23:18 ` mpolacek at gcc dot gnu.org 2022-06-24 3:25 ` luoxhu at gcc dot gnu.org 2022-06-24 13:03 ` mpolacek at gcc dot gnu.org 2022-06-30 8:13 ` luoxhu at gcc dot gnu.org 2022-06-30 8:15 ` luoxhu at gcc dot gnu.org 2022-06-30 17:32 ` segher at gcc dot gnu.org 2022-06-30 17:34 ` segher at gcc dot gnu.org 2022-07-01 1:52 ` luoxhu at gcc dot gnu.org 2022-07-25 15:54 ` rguenth at gcc dot gnu.org 2022-07-25 20:16 ` segher at gcc dot gnu.org 2022-07-25 20:18 ` segher at gcc dot gnu.org 2022-07-26 3:34 ` luoxhu at gcc dot gnu.org 2022-07-26 3:34 ` luoxhu at gcc dot gnu.org 2022-07-26 3:35 ` luoxhu at gcc dot gnu.org 2022-07-26 3:53 ` luoxhu at gcc dot gnu.org 2022-07-26 6:28 ` luoxhu at gcc dot gnu.org [this message] 2022-07-29 11:10 ` rguenth at gcc dot gnu.org 2022-07-29 11:21 ` rguenth at gcc dot gnu.org 2022-08-03 6:10 ` yinyuefengyi at gmail dot com 2022-08-03 6:38 ` yinyuefengyi at gmail dot com 2022-08-03 8:06 ` linkw at gcc dot gnu.org 2022-08-03 8:24 ` rguenther at suse dot de 2022-08-03 8:50 ` linkw at gcc dot gnu.org 2022-08-03 8:59 ` rguenth at gcc dot gnu.org 2022-08-03 9:20 ` rsandifo at gcc dot gnu.org 2022-08-03 9:25 ` rsandifo at gcc dot gnu.org 2022-08-03 18:01 ` segher at gcc dot gnu.org 2022-08-03 18:06 ` segher at gcc dot gnu.org 2022-08-04 9:17 ` rsandifo at gcc dot gnu.org 2022-08-04 9:21 ` rearnsha at gcc dot gnu.org 2022-08-04 9:59 ` yinyuefengyi at gmail dot com 2022-08-04 10:01 ` yinyuefengyi at gmail dot com 2023-01-16 18:00 ` jakub at gcc dot gnu.org 2023-03-24 16:16 ` jakub at gcc dot gnu.org 2023-03-24 17:01 ` bergner at gcc dot gnu.org 2023-03-31 2:57 ` yinyuefengyi at gmail dot com 2023-05-08 12:24 ` [Bug target/106069] [12/13/14 " rguenth 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-106069-4-F0ow7K3Oxo@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).