Port-powerpc archive

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

Re: spr register



>>>>> Emmanuel Dreyfus writes:

Emmanuel> In one special purpose register, there is the type of the CPU stored. 
I
Emmanuel> need it for COMPAT_MACH. Is there a place accessible in C where we 
store
Emmanuel> it? If not, what assembly would I need to get the value?

        Do you mean the Processor Version Register (PVR)?  You can get the
value from that register with the 

        mfpvr rD

assembly language, where "rD" is the destination register you choose.
The assembler converts this to a mfspr instruction with the appropriate
SPR number for the PVR.

David



Home | Main Index | Thread Index | Old Index