From: Richard Henderson <richard.henderson@linaro.org>
To: Chinmay Rath <rathc@linux.ibm.com>, qemu-ppc@nongnu.org
Cc: qemu-devel@nongnu.org, npiggin@gmail.com, danielhb413@gmail.com,
harshpb@linux.ibm.com
Subject: Re: [PATCH 1/3] target/ppc: Move VMX storage access instructions to decodetree
Date: Mon, 29 Apr 2024 05:48:09 -0700 [thread overview]
Message-ID: <0e33df55-9feb-403f-be87-952efdbaccd5@linaro.org> (raw)
In-Reply-To: <20240429051317.289426-2-rathc@linux.ibm.com>
On 4/28/24 22:13, Chinmay Rath wrote:
> +static bool trans_LVX(DisasContext *ctx, arg_X *a)
> +{
> + TCGv EA;
> + TCGv_i64 avr;
> + REQUIRE_INSNS_FLAGS(ctx, ALTIVEC);
> + REQUIRE_VECTOR(ctx);
> + gen_set_access_type(ctx, ACCESS_INT);
> + avr = tcg_temp_new_i64();
> + EA = do_ea_calc(ctx, a->ra, cpu_gpr[a->rb]);
> + tcg_gen_andi_tl(EA, EA, ~0xf);
> + /*
> + * We only need to swap high and low halves. gen_qemu_ld64_i64
> + * does necessary 64-bit byteswap already.
> + */
> + gen_qemu_ld64_i64(ctx, avr, EA);
> + set_avr64(a->rt, avr, !ctx->le_mode);
> + tcg_gen_addi_tl(EA, EA, 8);
> + gen_qemu_ld64_i64(ctx, avr, EA);
> + set_avr64(a->rt, avr, ctx->le_mode);
> + return true;
> +}
This is an accurate transcription of the current code, so,
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
but at some point this should use tcg_gen_qemu_ld_i128, with the proper atomicity flags.
r~
next prev parent reply other threads:[~2024-04-29 12:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-29 5:13 [PATCH 0/3] target/ppc: Moving VMX insns to decodetree Chinmay Rath
2024-04-29 5:13 ` [PATCH 1/3] target/ppc: Move VMX storage access instructions " Chinmay Rath
2024-04-29 12:48 ` Richard Henderson [this message]
2024-04-29 5:13 ` [PATCH 2/3] target/ppc: Move VMX integer logical " Chinmay Rath
2024-04-29 12:48 ` Richard Henderson
2024-04-29 5:13 ` [PATCH 3/3] target/ppc: Move VMX integer max/min " Chinmay Rath
2024-04-29 12:49 ` Richard Henderson
2024-05-18 9:05 ` [PATCH 0/3] target/ppc: Moving VMX insns " Nicholas Piggin
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=0e33df55-9feb-403f-be87-952efdbaccd5@linaro.org \
--to=richard.henderson@linaro.org \
--cc=danielhb413@gmail.com \
--cc=harshpb@linux.ibm.com \
--cc=npiggin@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=rathc@linux.ibm.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).