On Mon, Sep 12, 2022 at 3:56 PM Richard Henderson
wrote:
> > +static void gen_SSE4a_I(DisasContext *s, CPUX86State *env, X86DecodedInsn
> > *decode)
> > +{
> > +TCGv_i32 length = tcg_const_i32(decode->immediate & 255);
> > +TCGv_i32 index = tcg_const_i32(decode->immediate >> 8);
> > +
>
On 9/12/22 00:04, Paolo Bonzini wrote:
+static void gen_MOVD_from(DisasContext *s, CPUX86State *env, X86DecodedInsn
*decode)
+{
+MemOp ot = decode->op[2].ot;
+int lo_ofs = decode->op[2].offset
+- xmm_offset(decode->op[2].ot)
++ xmm_offset(ot);
+
+switch (ot) {
+
These are a mixed match, including the first two horizontal
(66 and F2 only) operations, more moves, and SSE4a extract/insert.
Because SSE4a is pretty rare, I chose to leave the helper as they are,
but it is possible to unify them by loading index and length from the
source XMM register.