This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: [PATCH] Handle mtsprg and mfsprg properly for BookE
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: Jeff Baker <jbaker at qnx dot com>
- Cc: binutils at sources dot redhat dot com,Alex Rosenberg <alexr at leftfield dot org>,Kumar Gala <kumar dot gala at freescale dot com>
- Date: Thu, 17 Mar 2005 21:39:26 +1030
- Subject: Re: [PATCH] Handle mtsprg and mfsprg properly for BookE
- References: <20050314041420.GJ13506@bubble.modra.org> <423850D0.3020708@qnx.com>
On Wed, Mar 16, 2005 at 10:29:20AM -0500, Jeff Baker wrote:
> The IBM PPC440 doesn't support reading from the supervisory SPR's (you
> get garbage values back) - the mfsprg's won't be too useful. E.g.:
>
> running the following code (MSR.PR=0) (PVR=0x41020481):
>
> li %r7,-1
> li %r8,-1
> li %r6,1
> mtspr 276,%r6
> mfspr %r7,260
> mfspr %r8,276
>
> leaves R7 with a 1 and R8 with a 0.
That's good enough for me. We'll leave things as they are.
--
Alan Modra
IBM OzLabs - Linux Technology Centre