From 6ae9b8025a3b9df3aa4f1e0b2ecf035cdd5eb556 Mon Sep 17 00:00:00 2001 From: Mark Pizzolato Date: Wed, 1 May 2019 04:20:51 -0700 Subject: [PATCH] Full VAX Simulators: Fix inverted instruction set test --- VAX/vax_cis.c | 8 ++++---- VAX/vax_cpu.c | 2 +- VAX/vax_defs.h | 8 +++++--- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/VAX/vax_cis.c b/VAX/vax_cis.c index 268e33c4..186e5409 100644 --- a/VAX/vax_cis.c +++ b/VAX/vax_cis.c @@ -107,10 +107,10 @@ t_stat r; DSTR accum, src1, src2, dst; DSTR mptable[10]; -if (!(((IG_PACKD == DR_GETIGRP(drom[opc][0])) && - (cpu_instruction_set & VAX_PACKED)) || - ((IG_EMONL == DR_GETIGRP(drom[opc][0])) && - (cpu_instruction_set & VAX_EMONL)))) { /* Emulated? */ +if (((IG_PACKD == DR_GETIGRP(drom[opc][0])) && + (cpu_instruction_set & VAX_PACKED)) || + ((IG_EMONL == DR_GETIGRP(drom[opc][0])) && + (cpu_instruction_set & VAX_EMONL))) { /* Emulated? */ /* CIS and emulate only instructions - invoke emulator interface opnd[0:5] = six operands to be pushed (if PSL = 0) cc = condition codes diff --git a/VAX/vax_cpu.c b/VAX/vax_cpu.c index 554237a1..73058c86 100644 --- a/VAX/vax_cpu.c +++ b/VAX/vax_cpu.c @@ -3829,7 +3829,7 @@ fprintf (st, "Implementing: "); if ((cpu_instruction_set & FULL_INSTRUCTION_SET) == FULL_INSTRUCTION_SET) { fprintf (st, "All standard VAX instructions"); #if defined(CMPM_VAX) - fprintf (st, "and Compatibility mode"); + fprintf (st, " and Compatibility mode"); #endif if (sim_switches & SWMASK ('V')) cpu_show_instruction_group (st, cpu_instruction_set); diff --git a/VAX/vax_defs.h b/VAX/vax_defs.h index d559fc29..71910486 100644 --- a/VAX/vax_defs.h +++ b/VAX/vax_defs.h @@ -474,7 +474,7 @@ extern jmp_buf save_env; #define VAX_EXTAC (1 << DR_GETIGRP(IG_EXTAC)) #define VAX_EMONL (1 << DR_GETIGRP(IG_EMONL)) #define VAX_VECTR (1 << DR_GETIGRP(IG_VECTR)) -#define FULL_INSTRUCTION_SET (VAX_BASE | \ +#define FULL_INSTRUCTION_SET (VAX_FULL_BASE | \ (1 << DR_GETIGRP(IG_PACKD)) | \ (1 << DR_GETIGRP(IG_EXTAC)) | \ (1 << DR_GETIGRP(IG_EMONL))) @@ -1011,8 +1011,10 @@ extern int32 cpu_instruction_set; #define CPU_MODEL_MODIFIERS /* No model specific CPU modifiers */ #endif #ifndef CPU_INST_MODIFIERS -#define CPU_INST_MODIFIERS { MTAB_XTD|MTAB_VDV, 0, "INSTRUCTIONS", "INSTRUCTIONS={F-FLOAT|D-FLOAT}", \ - &cpu_set_instruction_set, &cpu_show_instruction_set, NULL, "Set/Show the CPU Instruction Set" }, +#define CPU_INST_MODIFIERS { MTAB_XTD|MTAB_VDV|MTAB_VALR|MTAB_NMO, 0, "INSTRUCTIONS", "INSTRUCTIONS={{NO}G-FLOAT|{NO}D-FLOAT|{NO}PACKED|{NO}EXTENDED|{NO}EMULATED}", \ + &cpu_set_instruction_set, NULL, NULL, "Set the CPU Instruction Set" }, \ + { MTAB_XTD|MTAB_VDV, 0, "INSTRUCTIONS", NULL, \ + NULL, &cpu_show_instruction_set, NULL, "Show the CPU Instruction Set (SHOW -V)" }, #endif #ifndef IDX_IMM_TEST #define IDX_IMM_TEST RSVD_ADDR_FAULT