mirror of
https://github.com/holub/mame
synced 2025-05-25 07:15:25 +03:00
Hooked up DSA/ESA instructions for PowerPC 602 (as no-ops for now).
polystar gets a little farther but crashes when the sub cpu attempts to enable interrupts. Removed HAS_PPC* in favor of a single HAS_POWERPC, and a single definition in cpu.mak for all PowerPC variants.
This commit is contained in:
parent
13fff98e5f
commit
c303794661
@ -1213,17 +1213,9 @@ $(CPUOBJ)/pdp1/pdp1.o: $(CPUSRC)/pdp1/pdp1.c \
|
|||||||
# Motorola PowerPC series
|
# Motorola PowerPC series
|
||||||
#-------------------------------------------------
|
#-------------------------------------------------
|
||||||
|
|
||||||
CPUDEFS += -DHAS_PPC403GA=$(if $(filter PPC403GA,$(CPUS)),1,0)
|
CPUDEFS += -DHAS_POWERPC=$(if $(filter POWERPC,$(CPUS)),1,0)
|
||||||
CPUDEFS += -DHAS_PPC403GCX=$(if $(filter PPC403GCX,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_PPC601=$(if $(filter PPC601,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_PPC602=$(if $(filter PPC602,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_PPC603=$(if $(filter PPC603,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_PPC603E=$(if $(filter PPC603E,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_PPC603R=$(if $(filter PPC603R,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_PPC604=$(if $(filter PPC604,$(CPUS)),1,0)
|
|
||||||
CPUDEFS += -DHAS_MPC8240=$(if $(filter MPC8240,$(CPUS)),1,0)
|
|
||||||
|
|
||||||
ifneq ($(filter PPC403GA PPC403GCX PPC601 PPC602 PPC603 PPC603E PPC603R PPC604 MPC8240,$(CPUS)),)
|
ifneq ($(filter POWERPC,$(CPUS)),)
|
||||||
OBJDIRS += $(CPUOBJ)/powerpc
|
OBJDIRS += $(CPUOBJ)/powerpc
|
||||||
CPUOBJS += $(CPUOBJ)/powerpc/ppccom.o $(CPUOBJ)/powerpc/ppcfe.o $(CPUOBJ)/powerpc/ppcdrc.o $(DRCOBJ)
|
CPUOBJS += $(CPUOBJ)/powerpc/ppccom.o $(CPUOBJ)/powerpc/ppcfe.o $(CPUOBJ)/powerpc/ppcdrc.o $(DRCOBJ)
|
||||||
DBGOBJS += $(CPUOBJ)/powerpc/ppc_dasm.o
|
DBGOBJS += $(CPUOBJ)/powerpc/ppc_dasm.o
|
||||||
|
@ -2624,7 +2624,6 @@ static UINT32 recompile_xoris(drc_core *drc, UINT32 op)
|
|||||||
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if HAS_PPC403
|
|
||||||
static UINT32 recompile_dccci(drc_core *drc, UINT32 op)
|
static UINT32 recompile_dccci(drc_core *drc, UINT32 op)
|
||||||
{
|
{
|
||||||
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
||||||
@ -2713,7 +2712,6 @@ static UINT32 recompile_invalid(drc_core *drc, UINT32 op)
|
|||||||
|
|
||||||
/* PowerPC 60x Recompilers */
|
/* PowerPC 60x Recompilers */
|
||||||
|
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_PPC604||HAS_MPC8240)
|
|
||||||
static UINT32 recompile_lfs(drc_core *drc,UINT32 op)
|
static UINT32 recompile_lfs(drc_core *drc,UINT32 op)
|
||||||
{
|
{
|
||||||
emit_mov_m32_r32(DRCTOP, MABS(&ppc_icount), REG_EBP);
|
emit_mov_m32_r32(DRCTOP, MABS(&ppc_icount), REG_EBP);
|
||||||
@ -3768,7 +3766,6 @@ static UINT32 recompile_fnmsubsx(drc_core *drc, UINT32 op)
|
|||||||
|
|
||||||
// PPC602
|
// PPC602
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
static UINT32 recompile_esa(drc_core *drc, UINT32 op)
|
static UINT32 recompile_esa(drc_core *drc, UINT32 op)
|
||||||
{
|
{
|
||||||
emit_mov_m32_r32(DRCTOP, MABS(&ppc_icount), REG_EBP);
|
emit_mov_m32_r32(DRCTOP, MABS(&ppc_icount), REG_EBP);
|
||||||
@ -3790,19 +3787,14 @@ static UINT32 recompile_dsa(drc_core *drc, UINT32 op)
|
|||||||
|
|
||||||
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
||||||
}
|
}
|
||||||
#endif /* HAS_PPC602 */
|
|
||||||
|
|
||||||
#if (HAS_PPC602 || HAS_MPC8240)
|
|
||||||
static UINT32 recompile_tlbli(drc_core *drc, UINT32 op)
|
static UINT32 recompile_tlbli(drc_core *drc, UINT32 op)
|
||||||
{
|
{
|
||||||
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC602||HAS_PPC604||HAS_MPC8240)
|
|
||||||
static UINT32 recompile_tlbld(drc_core *drc, UINT32 op)
|
static UINT32 recompile_tlbld(drc_core *drc, UINT32 op)
|
||||||
{
|
{
|
||||||
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
return RECOMPILE_SUCCESSFUL_CP(1,4);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
|
@ -77,17 +77,11 @@ static const int mpc603r_pll_config[12][9] =
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC603 || HAS_PPC601 || HAS_PPC604)
|
|
||||||
static void ppc603_exception(int exception);
|
static void ppc603_exception(int exception);
|
||||||
#endif
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
static void ppc602_exception(int exception);
|
static void ppc602_exception(int exception);
|
||||||
#endif
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
static void ppc403_exception(int exception);
|
static void ppc403_exception(int exception);
|
||||||
static UINT8 ppc403_spu_r(UINT32 a);
|
static UINT8 ppc403_spu_r(UINT32 a);
|
||||||
static void ppc403_spu_w(UINT32 a, UINT8 d);
|
static void ppc403_spu_w(UINT32 a, UINT8 d);
|
||||||
#endif
|
|
||||||
|
|
||||||
#define RD ((op >> 21) & 0x1F)
|
#define RD ((op >> 21) & 0x1F)
|
||||||
#define RT ((op >> 21) & 0x1f)
|
#define RT ((op >> 21) & 0x1f)
|
||||||
@ -144,9 +138,7 @@ static void ppc403_spu_w(UINT32 a, UINT8 d);
|
|||||||
if((ppc.msr & 0x2000) == 0){ \
|
if((ppc.msr & 0x2000) == 0){ \
|
||||||
}
|
}
|
||||||
|
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_PPC604||HAS_MPC8240)
|
|
||||||
static UINT32 ppc_field_xlat[256];
|
static UINT32 ppc_field_xlat[256];
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -323,12 +315,8 @@ typedef struct {
|
|||||||
FPR fpr[32];
|
FPR fpr[32];
|
||||||
UINT32 sr[16];
|
UINT32 sr[16];
|
||||||
|
|
||||||
#if HAS_PPC603 || HAS_PPC601 || HAS_MPC8240 || HAS_PPC604
|
|
||||||
int is603;
|
int is603;
|
||||||
#endif
|
|
||||||
#if HAS_PPC602
|
|
||||||
int is602;
|
int is602;
|
||||||
#endif
|
|
||||||
|
|
||||||
/* PowerPC 602 specific registers */
|
/* PowerPC 602 specific registers */
|
||||||
UINT32 lt;
|
UINT32 lt;
|
||||||
@ -388,29 +376,17 @@ static UINT32 ppc_rotate_mask[32][32];
|
|||||||
|
|
||||||
INLINE int IS_PPC602(void)
|
INLINE int IS_PPC602(void)
|
||||||
{
|
{
|
||||||
#if HAS_PPC602
|
|
||||||
return ppc.is602;
|
return ppc.is602;
|
||||||
#else
|
|
||||||
return 0;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
INLINE int IS_PPC603(void)
|
INLINE int IS_PPC603(void)
|
||||||
{
|
{
|
||||||
#if HAS_PPC603 || HAS_PPC601 || HAS_PPC604
|
|
||||||
return ppc.is603;
|
return ppc.is603;
|
||||||
#else
|
|
||||||
return 0;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
INLINE int IS_PPC403(void)
|
INLINE int IS_PPC403(void)
|
||||||
{
|
{
|
||||||
#if HAS_PPC403
|
|
||||||
return !IS_PPC602() && !IS_PPC603();
|
return !IS_PPC602() && !IS_PPC603();
|
||||||
#else
|
|
||||||
return 0;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*********************************************************************/
|
/*********************************************************************/
|
||||||
@ -560,7 +536,6 @@ INLINE void ppc_set_spr(int spr, UINT32 value)
|
|||||||
case SPR_PVR: return;
|
case SPR_PVR: return;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if (HAS_PPC603 || HAS_PPC602 || HAS_PPC601 || HAS_PPC604)
|
|
||||||
if(IS_PPC602() || IS_PPC603()) {
|
if(IS_PPC602() || IS_PPC603()) {
|
||||||
switch(spr)
|
switch(spr)
|
||||||
{
|
{
|
||||||
@ -568,14 +543,10 @@ INLINE void ppc_set_spr(int spr, UINT32 value)
|
|||||||
if((value & 0x80000000) && !(DEC & 0x80000000))
|
if((value & 0x80000000) && !(DEC & 0x80000000))
|
||||||
{
|
{
|
||||||
/* trigger interrupt */
|
/* trigger interrupt */
|
||||||
#if HAS_PPC602
|
|
||||||
if (IS_PPC602())
|
if (IS_PPC602())
|
||||||
ppc602_exception(EXCEPTION_DECREMENTER);
|
ppc602_exception(EXCEPTION_DECREMENTER);
|
||||||
#endif
|
|
||||||
#if HAS_PPC603 || HAS_PPC601 || HAS_PPC604
|
|
||||||
if (IS_PPC603())
|
if (IS_PPC603())
|
||||||
ppc603_exception(EXCEPTION_DECREMENTER);
|
ppc603_exception(EXCEPTION_DECREMENTER);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
write_decrementer(value);
|
write_decrementer(value);
|
||||||
return;
|
return;
|
||||||
@ -629,9 +600,7 @@ INLINE void ppc_set_spr(int spr, UINT32 value)
|
|||||||
case SPR603E_IABR: ppc.iabr = value; return;
|
case SPR603E_IABR: ppc.iabr = value; return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
if (ppc.is602) {
|
if (ppc.is602) {
|
||||||
switch(spr)
|
switch(spr)
|
||||||
{
|
{
|
||||||
@ -643,9 +612,7 @@ INLINE void ppc_set_spr(int spr, UINT32 value)
|
|||||||
case SPR602_TCR: ppc.tcr = value; return;
|
case SPR602_TCR: ppc.tcr = value; return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
if (IS_PPC403()) {
|
if (IS_PPC403()) {
|
||||||
switch(spr)
|
switch(spr)
|
||||||
{
|
{
|
||||||
@ -702,7 +669,6 @@ INLINE void ppc_set_spr(int spr, UINT32 value)
|
|||||||
case SPR403_IAC2: ppc.iac2 = value; return;
|
case SPR403_IAC2: ppc.iac2 = value; return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
fatalerror("ppc: set_spr: unknown spr %d (%03X) !", spr, spr);
|
fatalerror("ppc: set_spr: unknown spr %d (%03X) !", spr, spr);
|
||||||
}
|
}
|
||||||
@ -723,7 +689,6 @@ INLINE UINT32 ppc_get_spr(int spr)
|
|||||||
case SPR_PVR: return ppc.pvr;
|
case SPR_PVR: return ppc.pvr;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
if (IS_PPC403())
|
if (IS_PPC403())
|
||||||
{
|
{
|
||||||
switch (spr)
|
switch (spr)
|
||||||
@ -754,9 +719,7 @@ INLINE UINT32 ppc_get_spr(int spr)
|
|||||||
case SPR403_IAC2: return ppc.iac2;
|
case SPR403_IAC2: return ppc.iac2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
if (ppc.is602) {
|
if (ppc.is602) {
|
||||||
switch(spr)
|
switch(spr)
|
||||||
{
|
{
|
||||||
@ -769,9 +732,7 @@ INLINE UINT32 ppc_get_spr(int spr)
|
|||||||
case SPR602_TCR: return ppc.tcr;
|
case SPR602_TCR: return ppc.tcr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603 || HAS_PPC602 || HAS_PPC601 || HAS_PPC604)
|
|
||||||
if (IS_PPC603() || IS_PPC602())
|
if (IS_PPC603() || IS_PPC602())
|
||||||
{
|
{
|
||||||
switch (spr)
|
switch (spr)
|
||||||
@ -819,7 +780,6 @@ INLINE UINT32 ppc_get_spr(int spr)
|
|||||||
case SPR603E_DBAT3U: return ppc.dbat[3].u;
|
case SPR603E_DBAT3U: return ppc.dbat[3].u;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
fatalerror("ppc: get_spr: unknown spr %d (%03X) !", spr, spr);
|
fatalerror("ppc: get_spr: unknown spr %d (%03X) !", spr, spr);
|
||||||
return 0;
|
return 0;
|
||||||
@ -899,17 +859,9 @@ INLINE void ppc_exception(int exception_type)
|
|||||||
|
|
||||||
#include "ppc_mem.c"
|
#include "ppc_mem.c"
|
||||||
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
#include "ppc403.c"
|
#include "ppc403.c"
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
#include "ppc602.c"
|
#include "ppc602.c"
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603 || HAS_PPC601 || HAS_MPC8240 || HAS_PPC604)
|
|
||||||
#include "ppc603.c"
|
#include "ppc603.c"
|
||||||
#endif
|
|
||||||
|
|
||||||
/********************************************************************/
|
/********************************************************************/
|
||||||
|
|
||||||
@ -974,7 +926,6 @@ static void ppc_init(void)
|
|||||||
|
|
||||||
|
|
||||||
// !!! probably should move this stuff elsewhere !!!
|
// !!! probably should move this stuff elsewhere !!!
|
||||||
#if HAS_PPC403
|
|
||||||
static CPU_INIT( ppc403 )
|
static CPU_INIT( ppc403 )
|
||||||
{
|
{
|
||||||
const ppc_config *configdata = device->static_config;
|
const ppc_config *configdata = device->static_config;
|
||||||
@ -1020,10 +971,7 @@ static CPU_EXIT( ppc403 )
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif /* HAS_PPC403 */
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC603)
|
|
||||||
static CPU_INIT( ppc603 )
|
static CPU_INIT( ppc603 )
|
||||||
{
|
{
|
||||||
const ppc_config *configdata = device->static_config;
|
const ppc_config *configdata = device->static_config;
|
||||||
@ -1167,9 +1115,7 @@ static CPU_EXIT( ppc603 )
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
static CPU_INIT( ppc602 )
|
static CPU_INIT( ppc602 )
|
||||||
{
|
{
|
||||||
float multiplier;
|
float multiplier;
|
||||||
@ -1302,9 +1248,6 @@ static CPU_EXIT( ppc602 )
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_MPC8240)
|
|
||||||
|
|
||||||
static void mpc8240_tlbli(UINT32 op)
|
static void mpc8240_tlbli(UINT32 op)
|
||||||
{
|
{
|
||||||
@ -1446,10 +1389,7 @@ static CPU_EXIT( mpc8240 )
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC601)
|
|
||||||
static CPU_INIT( ppc601 )
|
static CPU_INIT( ppc601 )
|
||||||
{
|
{
|
||||||
const ppc_config *configdata = device->static_config;
|
const ppc_config *configdata = device->static_config;
|
||||||
@ -1577,9 +1517,7 @@ static CPU_EXIT( ppc601 )
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC604)
|
|
||||||
static CPU_INIT( ppc604 )
|
static CPU_INIT( ppc604 )
|
||||||
{
|
{
|
||||||
const ppc_config *configdata = device->static_config;
|
const ppc_config *configdata = device->static_config;
|
||||||
@ -1709,7 +1647,6 @@ static CPU_EXIT( ppc604 )
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -1766,7 +1703,6 @@ static CPU_SET_INFO( ppc )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
static CPU_SET_INFO( ppc403 )
|
static CPU_SET_INFO( ppc403 )
|
||||||
{
|
{
|
||||||
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 8)
|
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 8)
|
||||||
@ -1781,9 +1717,7 @@ static CPU_SET_INFO( ppc403 )
|
|||||||
default: ppc_set_info(state, info); break;
|
default: ppc_set_info(state, info); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603)
|
|
||||||
static CPU_SET_INFO( ppc603 )
|
static CPU_SET_INFO( ppc603 )
|
||||||
{
|
{
|
||||||
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
||||||
@ -1798,7 +1732,6 @@ static CPU_SET_INFO( ppc603 )
|
|||||||
default: ppc_set_info(state, info); break;
|
default: ppc_set_info(state, info); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
static CPU_GET_INFO( ppc )
|
static CPU_GET_INFO( ppc )
|
||||||
{
|
{
|
||||||
@ -1933,7 +1866,6 @@ static CPU_GET_INFO( ppc )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
CPU_GET_INFO( ppc403 )
|
CPU_GET_INFO( ppc403 )
|
||||||
{
|
{
|
||||||
switch(state)
|
switch(state)
|
||||||
@ -1959,9 +1891,7 @@ CPU_GET_INFO( ppc403 )
|
|||||||
default: CPU_GET_INFO_CALL(ppc); break;
|
default: CPU_GET_INFO_CALL(ppc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603)
|
|
||||||
CPU_GET_INFO( ppc603 )
|
CPU_GET_INFO( ppc603 )
|
||||||
{
|
{
|
||||||
switch(state)
|
switch(state)
|
||||||
@ -1994,11 +1924,7 @@ CPU_GET_INFO( ppc603 )
|
|||||||
default: CPU_GET_INFO_CALL(ppc); break;
|
default: CPU_GET_INFO_CALL(ppc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
/* PowerPC 602 */
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
static CPU_SET_INFO( ppc602 )
|
static CPU_SET_INFO( ppc602 )
|
||||||
{
|
{
|
||||||
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
||||||
@ -2043,11 +1969,8 @@ CPU_GET_INFO( ppc602 )
|
|||||||
default: CPU_GET_INFO_CALL(ppc); break;
|
default: CPU_GET_INFO_CALL(ppc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Motorola MPC8240 */
|
|
||||||
|
|
||||||
#if (HAS_MPC8240)
|
|
||||||
static CPU_SET_INFO( mpc8240 )
|
static CPU_SET_INFO( mpc8240 )
|
||||||
{
|
{
|
||||||
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
||||||
@ -2088,11 +2011,7 @@ CPU_GET_INFO( mpc8240 )
|
|||||||
default: CPU_GET_INFO_CALL(ppc); break;
|
default: CPU_GET_INFO_CALL(ppc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
/* PPC601 */
|
|
||||||
|
|
||||||
#if (HAS_PPC601)
|
|
||||||
static CPU_SET_INFO( ppc601 )
|
static CPU_SET_INFO( ppc601 )
|
||||||
{
|
{
|
||||||
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
||||||
@ -2133,11 +2052,7 @@ CPU_GET_INFO( ppc601 )
|
|||||||
default: CPU_GET_INFO_CALL(ppc); break;
|
default: CPU_GET_INFO_CALL(ppc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
/* PPC604 */
|
|
||||||
|
|
||||||
#if (HAS_PPC604)
|
|
||||||
static CPU_SET_INFO( ppc604 )
|
static CPU_SET_INFO( ppc604 )
|
||||||
{
|
{
|
||||||
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
if (state >= CPUINFO_INT_INPUT_STATE && state <= CPUINFO_INT_INPUT_STATE + 5)
|
||||||
@ -2178,4 +2093,3 @@ CPU_GET_INFO( ppc604 )
|
|||||||
default: CPU_GET_INFO_CALL(ppc); break;
|
default: CPU_GET_INFO_CALL(ppc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
@ -148,50 +148,32 @@ struct _powerpc_config
|
|||||||
PUBLIC FUNCTIONS
|
PUBLIC FUNCTIONS
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
#if (HAS_PPC403GA)
|
|
||||||
CPU_GET_INFO( ppc403ga );
|
CPU_GET_INFO( ppc403ga );
|
||||||
#define CPU_PPC403GA CPU_GET_INFO_NAME( ppc403ga )
|
#define CPU_PPC403GA CPU_GET_INFO_NAME( ppc403ga )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC403GCX)
|
|
||||||
CPU_GET_INFO( ppc403gcx );
|
CPU_GET_INFO( ppc403gcx );
|
||||||
#define CPU_PPC403GCX CPU_GET_INFO_NAME( ppc403gcx )
|
#define CPU_PPC403GCX CPU_GET_INFO_NAME( ppc403gcx )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC601)
|
|
||||||
CPU_GET_INFO( ppc601 );
|
CPU_GET_INFO( ppc601 );
|
||||||
#define CPU_PPC601 CPU_GET_INFO_NAME( ppc601 )
|
#define CPU_PPC601 CPU_GET_INFO_NAME( ppc601 )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
CPU_GET_INFO( ppc602 );
|
CPU_GET_INFO( ppc602 );
|
||||||
#define CPU_PPC602 CPU_GET_INFO_NAME( ppc602 )
|
#define CPU_PPC602 CPU_GET_INFO_NAME( ppc602 )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603)
|
|
||||||
CPU_GET_INFO( ppc603 );
|
CPU_GET_INFO( ppc603 );
|
||||||
#define CPU_PPC603 CPU_GET_INFO_NAME( ppc603 )
|
#define CPU_PPC603 CPU_GET_INFO_NAME( ppc603 )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603E)
|
|
||||||
CPU_GET_INFO( ppc603e );
|
CPU_GET_INFO( ppc603e );
|
||||||
#define CPU_PPC603E CPU_GET_INFO_NAME( ppc603e )
|
#define CPU_PPC603E CPU_GET_INFO_NAME( ppc603e )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC603R)
|
|
||||||
CPU_GET_INFO( ppc603r );
|
CPU_GET_INFO( ppc603r );
|
||||||
#define CPU_PPC603R CPU_GET_INFO_NAME( ppc603r )
|
#define CPU_PPC603R CPU_GET_INFO_NAME( ppc603r )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_PPC604)
|
|
||||||
CPU_GET_INFO( ppc604 );
|
CPU_GET_INFO( ppc604 );
|
||||||
#define CPU_PPC604 CPU_GET_INFO_NAME( ppc604 )
|
#define CPU_PPC604 CPU_GET_INFO_NAME( ppc604 )
|
||||||
#endif
|
|
||||||
|
|
||||||
#if (HAS_MPC8240)
|
|
||||||
CPU_GET_INFO( mpc8240 );
|
CPU_GET_INFO( mpc8240 );
|
||||||
#define CPU_MPC8240 CPU_GET_INFO_NAME( mpc8240 )
|
#define CPU_MPC8240 CPU_GET_INFO_NAME( mpc8240 )
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -176,14 +176,12 @@ static void ppc603_set_irq_line(int irqline, int state)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if HAS_PPC603
|
|
||||||
static void ppc603_set_smi_line(int state)
|
static void ppc603_set_smi_line(int state)
|
||||||
{
|
{
|
||||||
if( state ) {
|
if( state ) {
|
||||||
ppc.interrupt_pending |= 0x4;
|
ppc.interrupt_pending |= 0x4;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
INLINE void ppc603_check_interrupts(void)
|
INLINE void ppc603_check_interrupts(void)
|
||||||
{
|
{
|
||||||
|
@ -166,10 +166,12 @@ static const IDESCR itab[] =
|
|||||||
{ "dcread", D_OP(31)|D_XO(486), M_RA|M_RB, F_RT_RA_RB, 0 },
|
{ "dcread", D_OP(31)|D_XO(486), M_RA|M_RB, F_RT_RA_RB, 0 },
|
||||||
{ "divw", D_OP(31)|D_XO(491), M_RT|M_RA|M_RB|M_OE|M_RC, F_RT_RA_RB, FL_OE|FL_RC },
|
{ "divw", D_OP(31)|D_XO(491), M_RT|M_RA|M_RB|M_OE|M_RC, F_RT_RA_RB, FL_OE|FL_RC },
|
||||||
{ "divwu", D_OP(31)|D_XO(459), M_RT|M_RA|M_RB|M_OE|M_RC, F_RT_RA_RB, FL_OE|FL_RC },
|
{ "divwu", D_OP(31)|D_XO(459), M_RT|M_RA|M_RB|M_OE|M_RC, F_RT_RA_RB, FL_OE|FL_RC },
|
||||||
|
{ "dsa", D_OP(31)|D_XO(628), 0, 0, 0 },
|
||||||
{ "eciwx", D_OP(31)|D_XO(310), M_RT|M_RA|M_RB, F_RT_RA_0_RB, 0 },
|
{ "eciwx", D_OP(31)|D_XO(310), M_RT|M_RA|M_RB, F_RT_RA_0_RB, 0 },
|
||||||
{ "ecowx", D_OP(31)|D_XO(438), M_RT|M_RA|M_RB, F_RT_RA_0_RB, 0 },
|
{ "ecowx", D_OP(31)|D_XO(438), M_RT|M_RA|M_RB, F_RT_RA_0_RB, 0 },
|
||||||
{ "eieio", D_OP(31)|D_XO(854), 0, F_NONE, 0 },
|
{ "eieio", D_OP(31)|D_XO(854), 0, F_NONE, 0 },
|
||||||
{ "eqv", D_OP(31)|D_XO(284), M_RT|M_RA|M_RB|M_RC, F_RA_RT_RB, FL_RC },
|
{ "eqv", D_OP(31)|D_XO(284), M_RT|M_RA|M_RB|M_RC, F_RA_RT_RB, FL_RC },
|
||||||
|
{ "esa", D_OP(31)|D_XO(596), 0, 0, 0 },
|
||||||
{ "extsb", D_OP(31)|D_XO(954), M_RT|M_RA|M_RC, F_RA_RT, FL_RC },
|
{ "extsb", D_OP(31)|D_XO(954), M_RT|M_RA|M_RC, F_RA_RT, FL_RC },
|
||||||
{ "extsh", D_OP(31)|D_XO(922), M_RT|M_RA|M_RC, F_RA_RT, FL_RC },
|
{ "extsh", D_OP(31)|D_XO(922), M_RT|M_RA|M_RC, F_RA_RT, FL_RC },
|
||||||
{ "fabs", D_OP(63)|D_XO(264), M_RT|M_RB|M_RC, F_FRT_FRB, FL_RC },
|
{ "fabs", D_OP(63)|D_XO(264), M_RT|M_RB|M_RC, F_FRT_FRB, FL_RC },
|
||||||
|
@ -66,7 +66,6 @@ INLINE void WRITE64(UINT32 a, UINT64 d)
|
|||||||
|
|
||||||
/***********************************************************************/
|
/***********************************************************************/
|
||||||
|
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_PPC604||HAS_MPC8240)
|
|
||||||
static UINT16 ppc_read16_unaligned(const address_space *space, UINT32 a)
|
static UINT16 ppc_read16_unaligned(const address_space *space, UINT32 a)
|
||||||
{
|
{
|
||||||
return ((UINT16)ppc.read8(space, a+0) << 8) | ((UINT16)ppc.read8(space, a+1) << 0);
|
return ((UINT16)ppc.read8(space, a+0) << 8) | ((UINT16)ppc.read8(space, a+1) << 0);
|
||||||
@ -102,7 +101,6 @@ static void ppc_write64_unaligned(const address_space *space, UINT32 a, UINT64 d
|
|||||||
ppc.write32(space, a+0, (UINT32)(d >> 32));
|
ppc.write32(space, a+0, (UINT32)(d >> 32));
|
||||||
ppc.write32(space, a+4, (UINT32)(d));
|
ppc.write32(space, a+4, (UINT32)(d));
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
/***********************************************************************/
|
/***********************************************************************/
|
||||||
|
|
||||||
@ -296,7 +294,6 @@ exception:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if (HAS_PPC602||HAS_PPC603)
|
|
||||||
static int ppc_translate_address_cb(int space, offs_t *addr)
|
static int ppc_translate_address_cb(int space, offs_t *addr)
|
||||||
{
|
{
|
||||||
int success = 1;
|
int success = 1;
|
||||||
@ -308,7 +305,6 @@ static int ppc_translate_address_cb(int space, offs_t *addr)
|
|||||||
}
|
}
|
||||||
return success;
|
return success;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
static UINT8 ppc_read8_translated(const address_space *space, offs_t address)
|
static UINT8 ppc_read8_translated(const address_space *space, offs_t address)
|
||||||
{
|
{
|
||||||
@ -359,14 +355,12 @@ static void ppc_write64_translated(const address_space *space, offs_t address, U
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef PPC_DRC
|
#ifndef PPC_DRC
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_MPC8240)
|
|
||||||
static UINT32 ppc_readop_translated(const address_space *space, offs_t address)
|
static UINT32 ppc_readop_translated(const address_space *space, offs_t address)
|
||||||
{
|
{
|
||||||
ppc_translate_address(&address, PPC_TRANSLATE_CODE | PPC_TRANSLATE_READ);
|
ppc_translate_address(&address, PPC_TRANSLATE_CODE | PPC_TRANSLATE_READ);
|
||||||
return memory_read_dword_64be(space, address);
|
return memory_read_dword_64be(space, address);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
/***********************************************************************/
|
/***********************************************************************/
|
||||||
|
|
||||||
@ -380,7 +374,6 @@ static CPU_DISASSEMBLE( ppc )
|
|||||||
|
|
||||||
/***********************************************************************/
|
/***********************************************************************/
|
||||||
|
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_PPC604||HAS_MPC8240)
|
|
||||||
static CPU_READOP( ppc )
|
static CPU_READOP( ppc )
|
||||||
{
|
{
|
||||||
if (!(ppc.msr & MSR_IR))
|
if (!(ppc.msr & MSR_IR))
|
||||||
@ -441,4 +434,3 @@ static CPU_WRITE( ppc )
|
|||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
@ -4,12 +4,10 @@
|
|||||||
#include <math.h>
|
#include <math.h>
|
||||||
|
|
||||||
#ifndef PPC_DRC
|
#ifndef PPC_DRC
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_MPC8240)
|
|
||||||
static void ppc_unimplemented(UINT32 op)
|
static void ppc_unimplemented(UINT32 op)
|
||||||
{
|
{
|
||||||
fatalerror("ppc: Unimplemented opcode %08X at %08X", op, ppc.pc);
|
fatalerror("ppc: Unimplemented opcode %08X at %08X", op, ppc.pc);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
static void ppc_addx(UINT32 op)
|
static void ppc_addx(UINT32 op)
|
||||||
{
|
{
|
||||||
@ -1063,21 +1061,15 @@ static void ppc_rlwnmx(UINT32 op)
|
|||||||
#ifndef PPC_DRC
|
#ifndef PPC_DRC
|
||||||
static void ppc_sc(UINT32 op)
|
static void ppc_sc(UINT32 op)
|
||||||
{
|
{
|
||||||
#if (HAS_PPC603 || HAS_PPC601)
|
|
||||||
if (ppc.is603) {
|
if (ppc.is603) {
|
||||||
ppc603_exception(EXCEPTION_SYSTEM_CALL);
|
ppc603_exception(EXCEPTION_SYSTEM_CALL);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
if (ppc.is602) {
|
if (ppc.is602) {
|
||||||
ppc602_exception(EXCEPTION_SYSTEM_CALL);
|
ppc602_exception(EXCEPTION_SYSTEM_CALL);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
if (IS_PPC403()) {
|
if (IS_PPC403()) {
|
||||||
ppc403_exception(EXCEPTION_SYSTEM_CALL);
|
ppc403_exception(EXCEPTION_SYSTEM_CALL);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -1543,21 +1535,15 @@ static void ppc_tw(UINT32 op)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (exception) {
|
if (exception) {
|
||||||
#if (HAS_PPC603 || HAS_PPC601)
|
|
||||||
if (ppc.is603) {
|
if (ppc.is603) {
|
||||||
ppc603_exception(EXCEPTION_TRAP);
|
ppc603_exception(EXCEPTION_TRAP);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
if (ppc.is602) {
|
if (ppc.is602) {
|
||||||
ppc602_exception(EXCEPTION_TRAP);
|
ppc602_exception(EXCEPTION_TRAP);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
if (IS_PPC403()) {
|
if (IS_PPC403()) {
|
||||||
ppc403_exception(EXCEPTION_TRAP);
|
ppc403_exception(EXCEPTION_TRAP);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -1587,21 +1573,15 @@ static void ppc_twi(UINT32 op)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (exception) {
|
if (exception) {
|
||||||
#if (HAS_PPC603 || HAS_PPC601)
|
|
||||||
if (ppc.is603) {
|
if (ppc.is603) {
|
||||||
ppc603_exception(EXCEPTION_TRAP);
|
ppc603_exception(EXCEPTION_TRAP);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
if (ppc.is602) {
|
if (ppc.is602) {
|
||||||
ppc602_exception(EXCEPTION_TRAP);
|
ppc602_exception(EXCEPTION_TRAP);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
#if (HAS_PPC403)
|
|
||||||
if (IS_PPC403()) {
|
if (IS_PPC403()) {
|
||||||
ppc403_exception(EXCEPTION_TRAP);
|
ppc403_exception(EXCEPTION_TRAP);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -1777,7 +1757,6 @@ INLINE void set_fprf(FPR f)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC601||HAS_PPC602||HAS_PPC603||HAS_PPC604||HAS_MPC8240)
|
|
||||||
static void ppc_lfs(UINT32 op)
|
static void ppc_lfs(UINT32 op)
|
||||||
{
|
{
|
||||||
UINT32 ea = SIMM16;
|
UINT32 ea = SIMM16;
|
||||||
@ -2837,4 +2816,3 @@ static void ppc_fnmsubsx(UINT32 op)
|
|||||||
SET_CR1();
|
SET_CR1();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
@ -3709,6 +3709,11 @@ static int generate_instruction_1f(powerpc_state *ppc, drcuml_block *block, comp
|
|||||||
else
|
else
|
||||||
UML_AND(block, MSR32, MSR32, IMM(~MSR_EE)); // and msr,msr,~MSR_EE
|
UML_AND(block, MSR32, MSR32, IMM(~MSR_EE)); // and msr,msr,~MSR_EE
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
|
case 0x254: /* ESA */
|
||||||
|
case 0x274: /* DSA */
|
||||||
|
/* no-op for now */
|
||||||
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
@ -4189,8 +4194,6 @@ static void log_opcode_desc(drcuml_state *drcuml, const opcode_desc *desclist, i
|
|||||||
PPC 4XX VARIANTS
|
PPC 4XX VARIANTS
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
#if (HAS_PPC403GA || HAS_PPC403GCX)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppcdrc4xx_get_info - PowerPC 4XX-specific
|
ppcdrc4xx_get_info - PowerPC 4XX-specific
|
||||||
information getter
|
information getter
|
||||||
@ -4216,10 +4219,6 @@ static CPU_SET_INFO( ppcdrc4xx )
|
|||||||
ppc4xx_set_info(ppc, state, info);
|
ppc4xx_set_info(ppc, state, info);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC403GA)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc403ga_init - PowerPC 403GA-specific
|
ppc403ga_init - PowerPC 403GA-specific
|
||||||
@ -4255,10 +4254,6 @@ CPU_GET_INFO( ppc403ga )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC403GCX)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc403gcx_init - PowerPC 403GCX-specific
|
ppc403gcx_init - PowerPC 403GCX-specific
|
||||||
@ -4294,16 +4289,12 @@ CPU_GET_INFO( ppc403gcx )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
PPC 6XX VARIANTS
|
PPC 6XX VARIANTS
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
#if (HAS_PPC601)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc601_init - PowerPC 601-specific
|
ppc601_init - PowerPC 601-specific
|
||||||
initialization
|
initialization
|
||||||
@ -4337,10 +4328,6 @@ CPU_GET_INFO( ppc601 )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC602)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc602_init - PowerPC 602-specific
|
ppc602_init - PowerPC 602-specific
|
||||||
@ -4375,10 +4362,6 @@ CPU_GET_INFO( ppc602 )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC603)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc603_init - PowerPC 603-specific
|
ppc603_init - PowerPC 603-specific
|
||||||
@ -4413,10 +4396,6 @@ CPU_GET_INFO( ppc603 )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC603E)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc603e_init - PowerPC 603e-specific
|
ppc603e_init - PowerPC 603e-specific
|
||||||
@ -4451,10 +4430,6 @@ CPU_GET_INFO( ppc603e )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC603R)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc603r_init - PowerPC 603r-specific
|
ppc603r_init - PowerPC 603r-specific
|
||||||
@ -4489,10 +4464,6 @@ CPU_GET_INFO( ppc603r )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#if (HAS_PPC604)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
ppc604_init - PowerPC 604-specific
|
ppc604_init - PowerPC 604-specific
|
||||||
@ -4527,16 +4498,12 @@ CPU_GET_INFO( ppc604 )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/***************************************************************************
|
/***************************************************************************
|
||||||
PPC 6XX VARIANTS
|
MPC VARIANTS
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
#if (HAS_MPC8240)
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
mpc8240_init - PowerPC MPC8240-specific
|
mpc8240_init - PowerPC MPC8240-specific
|
||||||
initialization
|
initialization
|
||||||
@ -4569,5 +4536,3 @@ CPU_GET_INFO( mpc8240 )
|
|||||||
default: CPU_GET_INFO_CALL(ppcdrc); break;
|
default: CPU_GET_INFO_CALL(ppcdrc); break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
|
||||||
|
@ -97,6 +97,16 @@ INLINE int is_601_class(const powerpc_state *ppc)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*-------------------------------------------------
|
||||||
|
is_602_class - are we one of the 602 variants?
|
||||||
|
-------------------------------------------------*/
|
||||||
|
|
||||||
|
INLINE int is_602_class(const powerpc_state *ppc)
|
||||||
|
{
|
||||||
|
return (ppc->flavor == PPC_MODEL_602);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/*-------------------------------------------------
|
/*-------------------------------------------------
|
||||||
is_603_class - are we one of the 603 variants?
|
is_603_class - are we one of the 603 variants?
|
||||||
-------------------------------------------------*/
|
-------------------------------------------------*/
|
||||||
@ -1005,7 +1015,7 @@ static int describe_instruction_1f(powerpc_state *ppc, UINT32 op, opcode_desc *d
|
|||||||
|
|
||||||
case 0x3d2: /* TLBLD */
|
case 0x3d2: /* TLBLD */
|
||||||
case 0x3f2: /* TLBLI */
|
case 0x3f2: /* TLBLI */
|
||||||
if (!(ppc->cap & PPCCAP_603_MMU))
|
if (!(ppc->cap & PPCCAP_603_MMU) && !is_602_class(ppc))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
desc->flags |= OPFLAG_PRIVILEGED | OPFLAG_CAN_CAUSE_EXCEPTION;
|
desc->flags |= OPFLAG_PRIVILEGED | OPFLAG_CAN_CAUSE_EXCEPTION;
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1181,6 +1191,13 @@ static int describe_instruction_1f(powerpc_state *ppc, UINT32 op, opcode_desc *d
|
|||||||
if (op & MSR_EE)
|
if (op & MSR_EE)
|
||||||
desc->flags |= OPFLAG_CAN_EXPOSE_EXTERNAL_INT;
|
desc->flags |= OPFLAG_CAN_EXPOSE_EXTERNAL_INT;
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
|
case 0x254: /* ESA */
|
||||||
|
case 0x274: /* DSA */
|
||||||
|
if (!is_602_class(ppc))
|
||||||
|
return FALSE;
|
||||||
|
desc->flags |= OPFLAG_PRIVILEGED | OPFLAG_CAN_CAUSE_EXCEPTION;
|
||||||
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
@ -221,7 +221,7 @@ static VIDEO_UPDATE( m2 )
|
|||||||
UINT16 *d = BITMAP_ADDR16(bitmap, j, 0);
|
UINT16 *d = BITMAP_ADDR16(bitmap, j, 0);
|
||||||
for (i=0; i < 512; i++)
|
for (i=0; i < 512; i++)
|
||||||
{
|
{
|
||||||
d[i^3] = *fb++;
|
d[i^3] = *fb++ & 0x7fff;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -169,15 +169,7 @@ CPUS += H83334
|
|||||||
CPUS += V810
|
CPUS += V810
|
||||||
CPUS += M37702
|
CPUS += M37702
|
||||||
CPUS += M37710
|
CPUS += M37710
|
||||||
CPUS += PPC403GA
|
CPUS += POWERPC
|
||||||
CPUS += PPC403GCX
|
|
||||||
CPUS += PPC601
|
|
||||||
CPUS += PPC602
|
|
||||||
CPUS += PPC603
|
|
||||||
CPUS += PPC603E
|
|
||||||
CPUS += PPC603R
|
|
||||||
CPUS += PPC604
|
|
||||||
CPUS += MPC8240
|
|
||||||
CPUS += SE3208
|
CPUS += SE3208
|
||||||
CPUS += MC68HC11
|
CPUS += MC68HC11
|
||||||
CPUS += ADSP21062
|
CPUS += ADSP21062
|
||||||
|
Loading…
Reference in New Issue
Block a user