qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v5 08/28] target/mips: Add CPO PWBase register


From: Aleksandar Markovic
Subject: Re: [Qemu-devel] [PATCH v5 08/28] target/mips: Add CPO PWBase register
Date: Tue, 16 Oct 2018 15:08:25 +0000

> From: Philippe Mathieu-Daudé <address@hidden>

> > @@ -6948,6 +6969,11 @@ static void gen_dmfc0(DisasContext *ctx, TCGv arg, 
> > int reg, int sel)
> >              tcg_gen_ld_tl(arg, cpu_env, offsetof(CPUMIPSState, 
> > CP0_SegCtl2));
> >              rn = "SegCtl2";
> >              break;
> > +        case 5:
> > +            check_pw(ctx);
> > +            tcg_gen_ld_tl(arg, cpu_env, offsetof(CPUMIPSState, 
> > CP0_PWBase));

> Shouldn't you use gen_mfc0_load64()?

It looks to me that  tcg_gen_ld_tl() is appropriate here. It will properly 
handle endianess. There is no need for sign-extension here.

There are other 64-bit related issues wrt PWxxx registers in this patch, but 
this particular line looks OK to me.

Thanks,
Aleksandar



reply via email to

[Prev in Thread] Current Thread [Next in Thread]