From: Uros Bizjak <ubizjak@gmail.com>
To: Richard Biener <rguenther@suse.de>,
Uros Bizjak <ubizjak@gmail.com>,
Hongtao Liu <hongtao.liu@intel.com>,
"gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>,
Richard Sandiford <richard.sandiford@arm.com>
Subject: Re: [PATCH][RFC] Add x86 subadd SLP pattern
Date: Tue, 22 Jun 2021 12:17:02 +0200 [thread overview]
Message-ID: <CAFULd4bXMF8UiqSthK0qxAYwNndgVdWeuvLG1eQzT15OKEtYJQ@mail.gmail.com> (raw)
In-Reply-To: <mpta6nidym4.fsf@arm.com>
On Tue, Jun 22, 2021 at 11:42 AM Richard Sandiford
<richard.sandiford@arm.com> wrote:
> >> Well, the pattern is called addsub in the x86 world because highpart
> >> does add and lowpart does sub. In left-to-right writing systems
> >> highpart comes before lowpart, so you have addsub.
> >
> > The other targets mentioned do not seem to agree but I can live
> > with that, thus I'll change back to addsub.
>
> FWIW, subadd sounds clearer to me too. It seems surprising to put
> imaginary before real when interpreting something as complex, for example.
>
> Putting the highpart first feels especially odd on an LE system like x86…
The XMM vector is documented left to right with MSB at the left (c.f.
most significant *DIGIT* of the number at the left)
xmm[MSB] .... xmm[LSB]
so, looking at x86 ADDSUBPD insn documentation:
xmm2[127:64] xmm2[63:0]
( + -)
xmm1[127:64] xmm1[63:0]
(=)
xmm1[127:64] holds ADD
xmm1[63:0] holds SUB
xmm1[127:64] xmm1 [63:0]
ADD SUB
Uros.
next prev parent reply other threads:[~2021-06-22 10:17 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-17 9:44 Richard Biener
2021-06-17 9:54 ` Uros Bizjak
2021-06-17 10:00 ` Richard Biener
2021-06-17 10:09 ` Uros Bizjak
2021-06-17 9:59 ` Uros Bizjak
2021-06-17 10:43 ` Richard Biener
2021-06-17 13:47 ` Richard Biener
2021-06-22 9:42 ` Richard Sandiford
2021-06-22 10:17 ` Uros Bizjak [this message]
2021-06-22 10:34 ` Richard Biener
2021-06-22 10:49 ` Uros Bizjak
2021-06-24 11:07 ` Richard Biener
2021-06-24 14:25 ` Uros Bizjak
2021-06-25 6:48 ` Richard Biener
2021-06-25 7:55 ` Uros Bizjak
2021-06-17 10:24 ` Tamar Christina
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=CAFULd4bXMF8UiqSthK0qxAYwNndgVdWeuvLG1eQzT15OKEtYJQ@mail.gmail.com \
--to=ubizjak@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=hongtao.liu@intel.com \
--cc=rguenther@suse.de \
--cc=richard.sandiford@arm.com \
/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: link
Be 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).