Click to switch representation:
Instruction Set Overview OpCode Matrix Instruction Details
| -0 | -1 | -2 | -3 | -4 | -5 | -6 | -7 | -8 | -9 | -A | -B | -C | -D | -E | -F | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… | Loading… |
Each opcode has an associated color which represents the flag (combination) that is available to that opcode. Because of this, I only need to connect a single flag-bit to the controller, which saves address/input bits in order to be able to have a full 8-bit opcode input. The single flag-input-bit is selected with a 3-to-8 multiplexer from all the available flags. The control bits for the multiplexer are the three most significant bits of the opcode.
| Color/Opcode range | Available flag (combination) |
|---|---|
| 000xxxxx | ZF |
| 001xxxxx | CF |
| 010xxxxx | NF |
| 011xxxxx | VF |
| 100xxxxx | NF ⊕ VF |
| 101xxxxx | (NF ⊕ VF) ∨ ZF |
| 110xxxxx | CF ∨ ZF |
| 111xxxxx | not assigned yet |