This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [patch] correct handling of lswx and mtfsfi instructions in ppc simulator
- From: Andrew Cagney <ac131313 at cygnus dot com>
- To: Julien Ducourthial <jducourt at noos dot fr>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Sat, 23 Mar 2002 16:15:38 -0500
- Subject: Re: [patch] correct handling of lswx and mtfsfi instructions in ppc simulator
- References: <1007887536.12196.1.camel@athlon_force.localdomain>
> Hi,
>
> When running a program (which works ok on PPC boards) in the simulator:
> * the lswx instruction generates exceptions where it should not,
> * the mtfsi instruction is not recognized at all.
>
> After checking ppc-instructions :
> * it seems there are a few typos in the registers handling in
> lswx (using bytes or bits index instead of register numbers).
Yep.
> * the prefix of mtfsfi is 64 instead of 63 (from "Powerpc : The
> Programming Environment").
Yes.
> the patch below fixes both problems.
>
> 2001-12-09 Julien Ducourthial <jducourt@noos.fr>
> * ppc-instructions (lswx): do the register control with the
> register count. Initialize the right register in the loop.
> * (mtfsfi) : correct prefix for the instruction.
Thanks.
Andrew