[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 13/40] target/mips: Add emulation of misc nan
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH v3 13/40] target/mips: Add emulation of misc nanoMIPS instructions (pool32a0) |
Date: |
Thu, 19 Jul 2018 12:08:00 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 |
On 07/19/2018 05:54 AM, Stefan Markovic wrote:
> From: Yongbok Kim <address@hidden>
>
> Add emulation of nanoMIPS instructions that are situated in pool32a0.
>
> Signed-off-by: Yongbok Kim <address@hidden>
> Signed-off-by: Aleksandar Markovic <address@hidden>
> Signed-off-by: Stefan Markovic <address@hidden>
> Reviewed-by: Aleksandar Markovic <address@hidden>
> ---
> target/mips/translate.c | 190
> ++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 190 insertions(+)
>
> diff --git a/target/mips/translate.c b/target/mips/translate.c
> index 2c7f62e..81c2950 100644
> --- a/target/mips/translate.c
> +++ b/target/mips/translate.c
> @@ -16588,6 +16588,186 @@ static void gen_pool16c_nanomips_insn(DisasContext
> *ctx)
> }
> }
>
> +static void gen_pool32a0_nanomips_insn(DisasContext *ctx)
> +{
> + int rt = (ctx->opcode >> 21) & 0x1f;
> + int rs = (ctx->opcode >> 16) & 0x1f;
> + int rd = (ctx->opcode >> 11) & 0x1f;
extract32.
> + case NM_SOV:
> + {
> + TCGv t0 = tcg_temp_local_new();
> + TCGv t1 = tcg_temp_new();
> + TCGv t2 = tcg_temp_new();
> + TCGLabel *l1 = gen_new_label();
> +
> + gen_load_gpr(t1, rs);
> + gen_load_gpr(t2, rt);
> + tcg_gen_add_tl(t0, t1, t2);
> + tcg_gen_ext32s_tl(t0, t0);
> + tcg_gen_xor_tl(t1, t1, t2);
> + tcg_gen_xor_tl(t2, t0, t2);
> + tcg_gen_andc_tl(t1, t2, t1);
> +
> + tcg_gen_movi_tl(t0, 0);
> + tcg_gen_brcondi_tl(TCG_COND_GE, t1, 0, l1);
tcg_gen_setcondi_tl.
r~
- Re: [Qemu-devel] [PATCH v3 26/40] target/mips: Implement CP0 Config0.WR bit functionality, (continued)
- [Qemu-devel] [PATCH v3 23/40] target/mips: Implement emulation of nanoMIPS LLWP/SCWP pair, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 01/40] target/mips: Add preprocessor constants for nanoMIPS, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 30/40] target/mips: Adjust set_pc() for nanoMIPS, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 16/40] target/mips: Implement emulation of nanoMIPS ROTX instruction, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 13/40] target/mips: Add emulation of misc nanoMIPS instructions (pool32a0), Stefan Markovic, 2018/07/19
- Re: [Qemu-devel] [PATCH v3 13/40] target/mips: Add emulation of misc nanoMIPS instructions (pool32a0),
Richard Henderson <=
- [Qemu-devel] [PATCH v3 05/40] target/mips: Add nanoMIPS decoding and extraction utilities, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 22/40] target/mips: Add handling of branch delay slots for nanoMIPS, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 08/40] target/mips: Add emulation of nanoMIPS 16-bit logic instructions, Stefan Markovic, 2018/07/19
- [Qemu-devel] [PATCH v3 04/40] target/mips: Add decode_nanomips_opc() function, Stefan Markovic, 2018/07/19