Stage 9: Full implemntation + passing tests

This commit is contained in:
2025-11-07 18:03:45 +01:00
parent 2117f8155e
commit 036f432d76
10 changed files with 197 additions and 9 deletions
+15
View File
@@ -0,0 +1,15 @@
# expected: 000001BC, 000002BC
.text
_start:
add x1, x0, 0x00A
add x2, x0, 0x00B
beq x1, x2, finish # Should not jump
add x31, x0, 0x1BC
add x1, x0, 0x1BC
add x2, x0, 0x1BC
beq x1, x2, finish # Should jump to finish
add x31, x0, 0x3BC
finish:
add x31, x0, 0x2BC
+15
View File
@@ -0,0 +1,15 @@
# expected: 000001BC, 000002BC
.text
_start:
add x1, x0, -29
add x2, x0, -28
bge x1, x2, finish # Should not jump
add x31, x0, 0x1BC
add x1, x0, 12
add x2, x0, 12
bge x1, x2, finish # Should jump to finish
add x31, x0, 0x3BC
finish:
add x31, x0, 0x2BC
+15
View File
@@ -0,0 +1,15 @@
# expected: 000001BC, 000002BC
.text
_start:
add x1, x0, 21
add x2, x0, 22
bgeu x1, x2, finish # Should not jump
add x31, x0, 0x1BC
add x1, x0, 12
add x2, x0, 12
bgeu x1, x2, finish # Should jump to finish
add x31, x0, 0x3BC
finish:
add x31, x0, 0x2BC
+15
View File
@@ -0,0 +1,15 @@
# expected: 000001BC, 000002BC
.text
_start:
add x1, x0, -28
add x2, x0, -28
blt x1, x2, finish # Should not jump
add x31, x0, 0x1BC
add x1, x0, -28
add x2, x0, 12
blt x1, x2, finish # Should jump to finish
add x31, x0, 0x3BC
finish:
add x31, x0, 0x2BC
+15
View File
@@ -0,0 +1,15 @@
# expected: 000001BC, 000002BC
.text
_start:
add x1, x0, 28
add x2, x0, 28
bltu x1, x2, finish # Should not jump
add x31, x0, 0x1BC
add x1, x0, 12
add x2, x0, 24
bltu x1, x2, finish # Should jump to finish
add x31, x0, 0x3BC
finish:
add x31, x0, 0x2BC
+15
View File
@@ -0,0 +1,15 @@
# expected: 000001BC, 000002BC
.text
_start:
add x1, x0, 0x00B
add x2, x0, 0x00B
bne x1, x2, finish # Should not jump
add x31, x0, 0x1BC
add x1, x0, 0x1BA
add x2, x0, 0x1BC
bne x1, x2, finish # Should jump to finish
add x31, x0, 0x3BC
finish:
add x31, x0, 0x2BC