From: David Gibson <david@gibson.dropbear.id.au>
To: Richard Henderson <richard.henderson@linaro.org>
Cc: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>,
BALATON Zoltan <balaton@eik.bme.hu>,
qemu-ppc@nongnu.org, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH v3 2/8] target/ppc: rework vmrg{l, h}{b, h, w} instructions to use Vsr* macros
Date: Tue, 29 Jan 2019 13:28:47 +1100 [thread overview]
Message-ID: <20190129022847.GG1870@umbus.fritz.box> (raw)
In-Reply-To: <3f43ac97-26d0-98b3-a8b4-8102acb73457@linaro.org>
[-- Attachment #1: Type: text/plain, Size: 1436 bytes --]
On Sun, Jan 27, 2019 at 10:07:12AM -0800, Richard Henderson wrote:
> On 1/27/19 9:45 AM, Mark Cave-Ayland wrote:
> >> I would expect the i < n/2 loop to be faster, because the assignments are
> >> unconditional. FWIW.
> >
> > Do you have any idea as to how much faster? Is it something that would show
> > up as significant within the context of QEMU?
>
> I don't have any numbers on that, no.
>
> > As well as eliminating the HI_IDX/LO_IDX constants I do find the updated
> > version much easier to read, so I would prefer to keep it if possible.
> > What about unrolling the loop into 2 separate ones...
>
> I doubt that would be helpful.
>
> I would think that
>
> #define VMRG_DO(name, access, ofs)
> ...
> int i, half = ARRAY_SIZE(r->access(0)) / 2;
> ...
> for (i = 0; i < half; i++) {
> result.access(2 * i + 0) = a->access(i + ofs);
> result.access(2 * i + 1) = b->access(i + ofs);
> }
>
> where OFS = 0 for HI and half for LO is best. I find it quite readable, and it
> avoids duplicating code between LO and HI as you're currently doing.
Marc, Richard, where are we at with this?
Should I wait on a revised version of this patch before applying the
series?
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2019-01-29 4:45 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-27 9:02 [Qemu-devel] [PATCH v3 0/8] target/ppc: remove various endian hacks from int_helper.c Mark Cave-Ayland
2019-01-27 9:02 ` [Qemu-devel] [PATCH v3 1/8] target/ppc: implement complete set of Vsr* macros Mark Cave-Ayland
2019-01-28 9:19 ` David Gibson
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 2/8] target/ppc: rework vmrg{l, h}{b, h, w} instructions to use " Mark Cave-Ayland
2019-01-27 12:07 ` [Qemu-devel] [Qemu-ppc] " BALATON Zoltan
2019-01-27 15:19 ` Mark Cave-Ayland
2019-01-27 17:26 ` Richard Henderson
2019-01-27 17:45 ` Mark Cave-Ayland
2019-01-27 18:07 ` Richard Henderson
2019-01-29 2:28 ` David Gibson [this message]
2019-01-29 6:36 ` Mark Cave-Ayland
2019-01-29 18:49 ` Mark Cave-Ayland
2019-01-27 20:31 ` BALATON Zoltan
2019-01-27 20:47 ` BALATON Zoltan
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 3/8] target/ppc: rework vmul{e, o}{s, u}{b, " Mark Cave-Ayland
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 4/8] target/ppc: eliminate use of HI_IDX and LO_IDX macros from int_helper.c Mark Cave-Ayland
2019-01-27 19:13 ` Richard Henderson
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 5/8] target/ppc: eliminate use of EL_IDX " Mark Cave-Ayland
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 6/8] target/ppc: simplify VEXT_SIGNED macro in int_helper.c Mark Cave-Ayland
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 7/8] target/ppc: remove ROTRu32 and ROTRu64 macros from int_helper.c Mark Cave-Ayland
2019-01-27 9:03 ` [Qemu-devel] [PATCH v3 8/8] target/ppc: remove various HOST_WORDS_BIGENDIAN hacks in int_helper.c Mark Cave-Ayland
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=20190129022847.GG1870@umbus.fritz.box \
--to=david@gibson.dropbear.id.au \
--cc=balaton@eik.bme.hu \
--cc=mark.cave-ayland@ilande.co.uk \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=richard.henderson@linaro.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: 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 NNTP newsgroup(s).