Re: [PATCH 04/17] target/i386: add ALU load/writeback core

2022-08-25 Thread Richard Henderson
On 8/24/22 23:48, Paolo Bonzini wrote: On 8/25/22 02:23, Richard Henderson wrote: +    op->v = v; +} Surely this assignment... +static void gen_writeback(DisasContext *s, X86DecodedOp *op) +{ ... +    case X86_ALU_GPR: +    gen_op_mov_reg_v(s, op->ot, op->n, s->T0); ... can be used

Re: [PATCH 04/17] target/i386: add ALU load/writeback core

2022-08-25 Thread Paolo Bonzini
On 8/25/22 02:23, Richard Henderson wrote: +    op->v = v; +} Surely this assignment... +static void gen_writeback(DisasContext *s, X86DecodedOp *op) +{ ... +    case X86_ALU_GPR: +    gen_op_mov_reg_v(s, op->ot, op->n, s->T0); ... can be used here instead of hard-coding T0.  It

Re: [PATCH 04/17] target/i386: add ALU load/writeback core

2022-08-24 Thread Richard Henderson
On 8/24/22 10:31, Paolo Bonzini wrote: Add generic code generation that takes care of preparing operands around calls to decode.e.gen in a table-driven manner, so that ALU operations need not take care of that. Signed-off-by: Paolo Bonzini --- target/i386/tcg/decode-new.c.inc | 14 +++-

[PATCH 04/17] target/i386: add ALU load/writeback core

2022-08-24 Thread Paolo Bonzini
Add generic code generation that takes care of preparing operands around calls to decode.e.gen in a table-driven manner, so that ALU operations need not take care of that. Signed-off-by: Paolo Bonzini --- target/i386/tcg/decode-new.c.inc | 14 +++- target/i386/tcg/emit.c.inc | 62