mirror of
https://github.com/pnx/m16vm
synced 2026-06-16 03:44:55 +02:00
cpu: remove CPU_FLAGS_HALT (and flag variable from struct cpu_state).
we can get handle cpu halts without this flag. CPU's dont actually have these. exceptions are actually implemented as interrupts in real hardware.
This commit is contained in:
parent
76a72e6857
commit
0a58a7857f
2 changed files with 6 additions and 18 deletions
5
vm/cpu.h
5
vm/cpu.h
|
|
@ -25,8 +25,6 @@
|
|||
|
||||
#define CPU_NUM_REGS 16
|
||||
|
||||
#define CPU_FLAGS_HALT (1<<0)
|
||||
|
||||
struct cpu_state {
|
||||
// Registers r0, r15
|
||||
int16_t reg[CPU_NUM_REGS];
|
||||
|
|
@ -34,9 +32,6 @@ struct cpu_state {
|
|||
// Program counter
|
||||
uint16_t pc;
|
||||
|
||||
// flags
|
||||
unsigned char flags;
|
||||
|
||||
// Instruction
|
||||
unsigned char *instr_mem;
|
||||
unsigned long instr_cnt;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue