DP offset instructions, new demo programs.

Added DPUP and DPDN, which take a one byte operand specifying how far up or down to offset the Data Pointer.
Three Fibonacci generators using the print.asm library.
 - 8 bit values printing in decimal representation.
- 16 bit values printing in hexadecimal representation.
- 32 bit values printing in hexadecimal representation.
This commit is contained in:
Anachronaut
2024-11-01 12:13:13 -04:00
committed by GitHub
parent e5241beb51
commit f4c78e68ba
7 changed files with 332 additions and 90 deletions
+7 -11
View File
@@ -17,13 +17,11 @@ Instruction instruction_set[] = {
{0x01, "SUB"},
{0x02, "AND"},
{0x03, "OR"},
{0x04, "NOR"},
{0x05, "NAND"},
{0x06, "XOR"},
{0x07, "NOTA"},
{0x08, "NOTB"},
{0x09, "SHL"},
{0x0A, "SHR"},
{0x04, "XOR"},
{0x05, "NOTA"},
{0x06, "NOTB"},
{0x07, "SHL"},
{0x08, "SHR"},
// Branch Operations:
{0x10, "BRI"},
{0x11, "BRQ"},
@@ -31,10 +29,6 @@ Instruction instruction_set[] = {
{0x13, "BRB"},
{0x14, "BRC"},
{0x17, "CALL"},
{0x18, "CALLA"},
{0x19, "CALLB"},
{0x1A, "CALLQ"},
{0x1B, "CALLCF"},
{0x1F, "RET"},
// Register Operations:
{0x20, "RSTA"},
@@ -65,6 +59,8 @@ Instruction instruction_set[] = {
{0x45, "STA"},
{0x46, "STB"},
{0x47, "SETD"},
{0x48, "DPUP"},
{0x49, "DPDN"},
// Output Operations:
{0xD0, "OUTQ"},
{0xD1, "OUTA"},