inital commit кек

This commit is contained in:
SashegDev
2026-06-04 03:12:17 +00:00
parent 82675f402d
commit f2888dea3a
190 changed files with 18421 additions and 21 deletions
@@ -0,0 +1,9 @@
{
"opcode": 0,
"mnemonic": "NOP",
"args": [],
"cycles": 1,
"semantics": [
{"op": "nop"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 1,
"mnemonic": "MOV_A_B",
"cycles": 1,
"semantics": [
{"op": "copy", "from": "b", "to": "a"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 2,
"mnemonic": "MOV_IMM_A",
"cycles": 1,
"semantics": [
{"op": "load_imm", "to": "a", "value": "$next"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 3,
"mnemonic": "ADD_A_B",
"cycles": 2,
"semantics": [
{"op": "add", "from": "b", "to": "a", "result": "a"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 4,
"mnemonic": "SUB_A_B",
"cycles": 2,
"semantics": [
{"op": "sub", "from": "a", "to": "b", "result": "a"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 5,
"mnemonic": "JMP_A",
"cycles": 2,
"semantics": [
{"op": "jmp", "to": "a"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 6,
"mnemonic": "JZ_A",
"cycles": 2,
"semantics": [
{"op": "jcc", "to": "a", "condition": "zero,1"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 7,
"mnemonic": "JC_A",
"cycles": 2,
"semantics": [
{"op": "jcc", "to": "a", "condition": "carry,1"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 8,
"mnemonic": "CMP_A_B",
"cycles": 1,
"semantics": [
{"op": "cmp", "from": "a", "to": "b"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 9,
"mnemonic": "MOV_IMM_B",
"cycles": 1,
"semantics": [
{"op": "load_imm", "to": "b", "value": "$next"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 10,
"mnemonic": "STORE_A",
"cycles": 2,
"semantics": [
{"op": "store", "from": "a", "to": "mem[$next]"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 11,
"mnemonic": "LOAD_A",
"cycles": 2,
"semantics": [
{"op": "load", "from": "mem[$next]", "to": "a"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 12,
"mnemonic": "JMP_IMM",
"cycles": 2,
"semantics": [
{"op": "jmp_imm"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 13,
"mnemonic": "JZ_IMM",
"cycles": 2,
"semantics": [
{"op": "jcc_imm", "condition": "zero,1"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 14,
"mnemonic": "JC_IMM",
"cycles": 2,
"semantics": [
{"op": "jcc_imm", "condition": "carry,1"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 15,
"mnemonic": "INC_A",
"cycles": 1,
"semantics": [
{"op": "inc", "from": "a", "to": "a"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 16,
"mnemonic": "CALL_IMM",
"cycles": 3,
"semantics": [
{"op": "call", "to": "$next"}
]
}
@@ -0,0 +1,8 @@
{
"opcode": 17,
"mnemonic": "RET",
"cycles": 2,
"semantics": [
{"op": "ret"}
]
}
@@ -0,0 +1,9 @@
{
"opcode": 255,
"mnemonic": "HLT",
"args": [],
"cycles": 1,
"semantics": [
{"op": "nop"}
]
}