qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] Re: [PATCH 1/2] target-sh4: fix 64-bit fmov to/from memory


From: Måns Rullgård
Subject: [Qemu-devel] Re: [PATCH 1/2] target-sh4: fix 64-bit fmov to/from memory
Date: Fri, 21 Nov 2008 22:25:00 +0000
User-agent: Gnus/5.1008 (Gnus v5.10.8) XEmacs/21.4.21 (Educational Television, linux)

Aurelien Jarno <address@hidden> writes:

> On Fri, Nov 21, 2008 at 09:24:03PM +0000, Måns Rullgård wrote:
>> Aurelien Jarno <address@hidden> writes:
>> 
>> > On Fri, Nov 21, 2008 at 07:55:41PM +0000, Mans Rullgard wrote:
>> >> When loading/storing a register pair, the even-numbered register
>> >> always maps to the low 32 bits of memory independently of target
>> >> endian configuration.
>> >> 
>> >> Signed-off-by: Mans Rullgard <address@hidden>
>> >> ---
>> >>  target-sh4/translate.c |   63 
>> >> ++++++++++++++++++++++++-----------------------
>> >>  1 files changed, 32 insertions(+), 31 deletions(-)
>> >> 
>> >> diff --git a/target-sh4/translate.c b/target-sh4/translate.c
>> >> index 84a3f40..2d6dfe6 100644
>> >> --- a/target-sh4/translate.c
>> >> +++ b/target-sh4/translate.c
>> >> @@ -991,31 +991,35 @@ static void _decode_opc(DisasContext * ctx)
>> >>   return;
>> >>      case 0xf00a: /* fmov {F,D,X}Rm,@Rn - FPSCR: Nothing */
>> >>   if (ctx->fpscr & FPSCR_SZ) {
>> >> -     TCGv_i64 fp = tcg_temp_new_i64();
>> >> -     gen_load_fpr64(fp, XREG(B7_4));
>> >> -     tcg_gen_qemu_st64(fp, REG(B11_8), ctx->memidx);
>> >> -     tcg_temp_free_i64(fp);
>> >> +            TCGv addr_hi = tcg_temp_new();
>> >> +            int fr = XREG(B7_4);
>> >> +            tcg_gen_addi_i32(addr_hi, REG(B11_8), 4);
>> >> +            tcg_gen_qemu_st32(cpu_fregs[fr  ], REG(B11_8), ctx->memidx);
>> >> +            tcg_gen_qemu_st32(cpu_fregs[fr+1], addr_hi,    ctx->memidx);
>> >> +            tcg_temp_free(addr_hi);
>> >
>> > You are totally breaking the indendation. Care to resend this patch with
>> > a proper indentation?
>> 
>> I was told to use spaces for indentation even if surrounding code uses
>> tabs.  I'll be happy to convert it to tabs if that's what you want.
>
> The current file use tabs. While it is not consistent with other qemu
> files, I think mixed indentation is even worse.

I can agree with that.  New patch sent.

-- 
Måns Rullgård
address@hidden





reply via email to

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