diff options
Diffstat (limited to 'tests')
| -rwxr-xr-x[-rw-r--r--] | tests/test3.asm | 0 | ||||
| -rwxr-xr-x[-rw-r--r--] | tests/test3.bin | 0 | ||||
| -rwxr-xr-x | tests/test4.asm | 12 | ||||
| -rwxr-xr-x[-rw-r--r--] | tests/test4.bin | bin | 56 -> 56 bytes |
4 files changed, 7 insertions, 5 deletions
diff --git a/tests/test3.asm b/tests/test3.asm index e6ab8a6..e6ab8a6 100644..100755 --- a/tests/test3.asm +++ b/tests/test3.asm diff --git a/tests/test3.bin b/tests/test3.bin index e69de29..e69de29 100644..100755 --- a/tests/test3.bin +++ b/tests/test3.bin diff --git a/tests/test4.asm b/tests/test4.asm index af5dcc4..e116ac7 100755 --- a/tests/test4.asm +++ b/tests/test4.asm @@ -1,15 +1,17 @@ -addi $t0, $zero, 10 -addi $t1, $zero, 12 +# This is a test program to test the capabilities of the assembler + +addi $t0, $zero, 10 # load 10 into $t0 +addi $t1, $zero, 12 # load 12 into $t1 add $t2, $t1, $t0 -beq $zero, $zero, PrintInt +jal PrintInt nop -caller: beq $zero, $zero, Exit +j Exit # Exit the program nop PrintInt: add $a0, $t2, $zero addi $v0, $zero, 1 syscall -beq $zero, $zero, caller +jr $ra nop Exit: addi $v0, $zero, 10 diff --git a/tests/test4.bin b/tests/test4.bin Binary files differindex 1c6e0bd..61cb805 100644..100755 --- a/tests/test4.bin +++ b/tests/test4.bin |
