From: Stefan Weil <weil@mail.berlios.de>
To: qemu-devel@nongnu.org, Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [Qemu-devel] [6936] target-mips: optimize gen_compute_branch()
Date: Sun, 29 Mar 2009 22:39:58 +0200 [thread overview]
Message-ID: <49CFDC9E.6080405@mail.berlios.de> (raw)
In-Reply-To: <E1Lnjfp-000855-5q@cvs.savannah.gnu.org>
Aurelien Jarno schrieb:
> Revision: 6936
> http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6936
> Author: aurel32
> Date: 2009-03-29 01:18:52 +0000 (Sun, 29 Mar 2009)
> Log Message:
> -----------
> target-mips: optimize gen_compute_branch()
>
> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
>
> Modified Paths:
> --------------
> trunk/target-mips/cpu.h
> trunk/target-mips/machine.c
> trunk/target-mips/translate.c
>
> Modified: trunk/target-mips/cpu.h
> ===================================================================
> --- trunk/target-mips/cpu.h 2009-03-29 01:18:43 UTC (rev 6935)
> +++ trunk/target-mips/cpu.h 2009-03-29 01:18:52 UTC (rev 6936)
> @@ -443,7 +443,7 @@
> #define MIPS_HFLAG_BL 0x0C00 /* Likely branch */
> #define MIPS_HFLAG_BR 0x1000 /* branch to register (can't link TB) */
> target_ulong btarget; /* Jump / branch target */
> - int bcond; /* Branch condition (if needed) */
> + target_ulong bcond; /* Branch condition (if needed) */
>
> int SYNCI_Step; /* Address step size for SYNCI */
> int CCRes; /* Cycle count resolution/divisor */
>
> Modified: trunk/target-mips/machine.c
> ===================================================================
> --- trunk/target-mips/machine.c 2009-03-29 01:18:43 UTC (rev 6935)
> +++ trunk/target-mips/machine.c 2009-03-29 01:18:52 UTC (rev 6936)
> @@ -91,7 +91,8 @@
> qemu_put_sbe32s(f, &env->error_code);
> qemu_put_be32s(f, &env->hflags);
> qemu_put_betls(f, &env->btarget);
> - qemu_put_sbe32s(f, &env->bcond);
> + i = env->bcond;
> + qemu_put_sbe32s(f, &i);
>
bcond is now target_ulong (32 or 64 bit target), i is int.
Are the upper 32 bits of bcond not needed?
>
> /* Save remaining CP1 registers */
> qemu_put_sbe32s(f, &env->CP0_Index);
> @@ -240,7 +241,8 @@
> qemu_get_sbe32s(f, &env->error_code);
> qemu_get_be32s(f, &env->hflags);
> qemu_get_betls(f, &env->btarget);
> - qemu_get_sbe32s(f, &env->bcond);
> + qemu_get_sbe32s(f, &i);
> + env->bcond = i;
>
See above.
>
> /* Load remaining CP1 registers */
> qemu_get_sbe32s(f, &env->CP0_Index);
>
>
Regards
Stefan
next prev parent reply other threads:[~2009-03-29 20:40 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-29 1:18 [Qemu-devel] [6936] target-mips: optimize gen_compute_branch() Aurelien Jarno
2009-03-29 20:39 ` Stefan Weil [this message]
2009-03-29 22:11 ` Aurelien Jarno
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=49CFDC9E.6080405@mail.berlios.de \
--to=weil@mail.berlios.de \
--cc=aurelien@aurel32.net \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.