qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <richard.henderson@linaro.org>
To: Stefan Brankovic <stefan.brankovic@rt-rk.com>, qemu-devel@nongnu.org
Cc: hsp.cat7@gmail.com, david@gibson.dropbear.id.au
Subject: Re: [Qemu-devel] [PATCH v4 08/13] tcg: Add opcodes for vector vmrgh instructions
Date: Thu, 27 Jun 2019 13:39:48 +0200	[thread overview]
Message-ID: <fe916cb6-ecc4-dd46-6a65-b4a048321ac0@linaro.org> (raw)
In-Reply-To: <1561632985-24866-9-git-send-email-stefan.brankovic@rt-rk.com>

On 6/27/19 12:56 PM, Stefan Brankovic wrote:
> +void tcg_gen_gvec_vmrgh(unsigned vece, uint32_t dofs, uint32_t aofs,
> +                       uint32_t bofs, uint32_t oprsz, uint32_t maxsz)
> +{
> +    static const GVecGen3 g[3] = {
> +        { .fniv = tcg_gen_vmrgh_vec,
> +          .fno = gen_helper_gvec_vmrgh8,
> +          .opt_opc = vecop_list_vmrgh,
> +          .vece = MO_8 },
> +        { .fniv = tcg_gen_vmrgh_vec,
> +          .fno = gen_helper_gvec_vmrgh16,
> +          .opt_opc = vecop_list_vmrgh,
> +          .vece = MO_16 },
> +        { .fniv = tcg_gen_vmrgh_vec,
> +          .fno = gen_helper_gvec_vmrgh32,
> +          .opt_opc = vecop_list_vmrgh,
> +          .vece = MO_32 }
> +    };
> +    tcg_debug_assert(vece <= MO_64);
> +    tcg_gen_gvec_3(dofs, aofs, bofs, oprsz, maxsz, &g[vece]);

By the by, you've missed out on the 64-bit operation, which your assert allows
(and should be available, if this is supposed to be a generic operation).

Also, because this operation does not move data in strict columns between the
input and output vectors, you can't use tcg_gen_gvec_3.  You'd need to write
custom code in order to allow 2 VEC128 to implement the merge for a VEC256 (or
any other combination allowed by MAXSZ).


r~


  parent reply	other threads:[~2019-06-27 11:44 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-27 10:56 [Qemu-devel] [PATCH v4 00/13] target/ppc, tcg, tcg/i386: Optimize emulation of some Altivec instructions Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 01/13] target/ppc: Optimize emulation of lvsl and lvsr instructions Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 02/13] target/ppc: Optimize emulation of vsl and vsr instructions Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 03/13] target/ppc: Optimize emulation of vgbbd instruction Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 04/13] target/ppc: Optimize emulation of vclzd instruction Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 05/13] target/ppc: Optimize emulation of vclzw instruction Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 06/13] target/ppc: Optimize emulation of vclzh and vclzb instructions Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 07/13] target/ppc: Refactor emulation of vmrgew and vmrgow instructions Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 08/13] tcg: Add opcodes for vector vmrgh instructions Stefan Brankovic
2019-06-27 11:35   ` Richard Henderson
2019-06-27 11:39   ` Richard Henderson [this message]
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 09/13] tcg/i386: Implement " Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 10/13] target/ppc: convert vmrgh instructions to vector operations Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 11/13] tcg: Add opcodes for verctor vmrgl instructions Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 12/13] tcg/i386: Implement vector " Stefan Brankovic
2019-06-27 10:56 ` [Qemu-devel] [PATCH v4 13/13] target/ppc: convert vmrgl instructions to vector operations Stefan Brankovic
2019-06-27 20:19 ` [Qemu-devel] [PATCH v4 00/13] target/ppc, tcg, tcg/i386: Optimize emulation of some Altivec instructions Howard Spoelstra

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=fe916cb6-ecc4-dd46-6a65-b4a048321ac0@linaro.org \
    --to=richard.henderson@linaro.org \
    --cc=david@gibson.dropbear.id.au \
    --cc=hsp.cat7@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefan.brankovic@rt-rk.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 NNTP newsgroup(s).