Replace cpu_has* flags with single cpu_features variable and cpu_has_feature() getter.

This commit is contained in:
SarahW 2019-02-08 21:22:53 +00:00
commit ce4436054d
8 changed files with 53 additions and 87 deletions

View file

@ -21,7 +21,7 @@ static int opMOV_r_CRx_a16(uint32_t fetchdat)
cpu_state.regs[cpu_rm].l = cr3;
break;
case 4:
if (cpu_hasCR4)
if (cpu_has_feature(CPU_FEATURE_CR4))
{
cpu_state.regs[cpu_rm].l = cr4;
break;
@ -59,7 +59,7 @@ static int opMOV_r_CRx_a32(uint32_t fetchdat)
cpu_state.regs[cpu_rm].l = cr3;
break;
case 4:
if (cpu_hasCR4)
if (cpu_has_feature(CPU_FEATURE_CR4))
{
cpu_state.regs[cpu_rm].l = cr4;
break;
@ -144,7 +144,7 @@ static int opMOV_CRx_r_a16(uint32_t fetchdat)
flushmmucache();
break;
case 4:
if (cpu_hasCR4)
if (cpu_has_feature(CPU_FEATURE_CR4))
{
cr4 = cpu_state.regs[cpu_rm].l & cpu_CR4_mask;
break;
@ -200,7 +200,7 @@ static int opMOV_CRx_r_a32(uint32_t fetchdat)
flushmmucache();
break;
case 4:
if (cpu_hasCR4)
if (cpu_has_feature(CPU_FEATURE_CR4))
{
cr4 = cpu_state.regs[cpu_rm].l & cpu_CR4_mask;
break;