public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/107208] [aarch64] _complex integer return types could be improved Date: Tue, 11 Oct 2022 04:30:55 +0000 [thread overview] Message-ID: <bug-107208-4-CNGyjBXLx9@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-107208-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107208 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|[aarch64] llvm generate |[aarch64] _complex integer |better code than gcc base |return types could be |on _Complex type mul |improved Component|rtl-optimization |middle-end Last reconfirmed| |2022-10-11 Status|UNCONFIRMED |NEW Ever confirmed|0 |1 --- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Yes it is due to return value and how it is done: (insn 32 28 33 2 (clobber (reg/i:CDI 0 x0)) "/app/example.cpp":6:1 -1 (nil)) (insn 33 32 34 2 (set (reg:DI 0 x0) (reg:DI 102 [ <retval> ])) "/app/example.cpp":6:1 -1 (nil)) (insn 34 33 35 2 (set (reg:DI 1 x1 [+8 ]) (reg:DI 103 [ <retval>+8 ])) "/app/example.cpp":6:1 -1 (nil)) (insn 35 34 0 2 (use (reg/i:CDI 0 x0)) "/app/example.cpp":6:1 -1 (nil)) So this is not _Complex integer multiplies at all but rather just the return values and the register allocator. I wonder why Complex float is expanded slightly differently (and better here): (insn 34 33 35 2 (set (reg:SF 32 v0) (reg:SF 115)) "/app/example.cpp":6:1 -1 (nil)) (insn 35 34 36 2 (set (reg:SF 33 v1) (reg:SF 118)) "/app/example.cpp":6:1 -1 (nil)) (insn 36 35 37 2 (use (reg:SF 32 v0)) "/app/example.cpp":6:1 -1 (nil)) (insn 37 36 0 2 (use (reg:SF 33 v1)) "/app/example.cpp":6:1 -1 (nil)) Who chose CDI for the integer case but a pair of SF for the float case ...
next prev parent reply other threads:[~2022-10-11 4:30 UTC|newest] Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-10-11 3:07 [Bug c++/107208] New: [aarch64] llvm generate better code than gcc base on _Complex type mul zhongyunde at huawei dot com 2022-10-11 3:14 ` [Bug rtl-optimization/107208] " pinskia at gcc dot gnu.org 2022-10-11 4:30 ` pinskia at gcc dot gnu.org [this message] 2022-10-13 13:32 ` [Bug middle-end/107208] [aarch64] _complex integer return types could be improved zhongyunde at huawei dot com 2022-10-17 12:49 ` rearnsha 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-107208-4-CNGyjBXLx9@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).