mirror of
https://github.com/kanjitalk755/macemu.git
synced 2024-09-07 16:54:28 +00:00
implement mcrxr instruction
This commit is contained in:
parent
61e223471b
commit
a8a235345c
@ -390,6 +390,7 @@ private:
|
||||
void execute_stwcx(uint32 opcode);
|
||||
void execute_mcrf(uint32 opcode);
|
||||
void execute_mcrfs(uint32 opcode);
|
||||
void execute_mcrxr(uint32 opcode);
|
||||
void execute_mtcrf(uint32 opcode);
|
||||
template< class FM, class RB, class Rc >
|
||||
void execute_mtfsf(uint32 opcode);
|
||||
|
@ -814,6 +814,12 @@ const powerpc_cpu::instr_info_t powerpc_cpu::powerpc_ii_table[] = {
|
||||
PPC_I(MCRFS),
|
||||
X_form, 63, 64, CFLOW_NORMAL
|
||||
},
|
||||
{ "mcrxr",
|
||||
EXECUTE_0(mcrxr),
|
||||
NULL,
|
||||
PPC_I(MCRXR),
|
||||
X_form, 31, 512, CFLOW_NORMAL
|
||||
},
|
||||
{ "mfcr",
|
||||
EXECUTE_GENERIC_ARITH(nop, RD, CR, NONE, NONE, OE_BIT_0, RC_BIT_0),
|
||||
NULL,
|
||||
|
@ -953,6 +953,15 @@ void powerpc_cpu::execute_mcrfs(uint32 opcode)
|
||||
increment_pc(4);
|
||||
}
|
||||
|
||||
void powerpc_cpu::execute_mcrxr(uint32 opcode)
|
||||
{
|
||||
const int crfD = crfD_field::extract(opcode);
|
||||
const uint32 x = xer().get();
|
||||
cr().set(crfD, x >> 28);
|
||||
xer().set(x & 0x0fffffff);
|
||||
increment_pc(4);
|
||||
}
|
||||
|
||||
void powerpc_cpu::execute_mtcrf(uint32 opcode)
|
||||
{
|
||||
uint32 mask = field2mask[CRM_field::extract(opcode)];
|
||||
|
@ -141,6 +141,7 @@ enum powerpc_instruction {
|
||||
PPC_I(LWZX),
|
||||
PPC_I(MCRF),
|
||||
PPC_I(MCRFS),
|
||||
PPC_I(MCRXR),
|
||||
PPC_I(MFCR),
|
||||
PPC_I(MFFS),
|
||||
PPC_I(MFMSR),
|
||||
|
Loading…
Reference in New Issue
Block a user