diff options
Diffstat (limited to 'ue3/mycpu/test')
| -rw-r--r-- | ue3/mycpu/test/memory1 | 1 | ||||
| -rw-r--r-- | ue3/mycpu/test/program1 | 13 | ||||
| -rwxr-xr-x | ue3/mycpu/test/test.sh | 4 |
3 files changed, 3 insertions, 15 deletions
diff --git a/ue3/mycpu/test/memory1 b/ue3/mycpu/test/memory1 deleted file mode 100644 index 209e3ef..0000000 --- a/ue3/mycpu/test/memory1 +++ /dev/null | |||
| @@ -1 +0,0 @@ | |||
| 1 | 20 | ||
diff --git a/ue3/mycpu/test/program1 b/ue3/mycpu/test/program1 deleted file mode 100644 index ae5e9d2..0000000 --- a/ue3/mycpu/test/program1 +++ /dev/null | |||
| @@ -1,13 +0,0 @@ | |||
| 1 | # set R2 = 10 | ||
| 2 | LOAD R2, R1 | ||
| 3 | |||
| 4 | # start of loop | ||
| 5 | label Loop: | ||
| 6 | inc R3 | ||
| 7 | sub R4, R3, R2 | ||
| 8 | test R4 | ||
| 9 | jumpz EndLoop | ||
| 10 | write WDEZ, R3 | ||
| 11 | jumpa Loop | ||
| 12 | |||
| 13 | label EndLoop: | ||
diff --git a/ue3/mycpu/test/test.sh b/ue3/mycpu/test/test.sh index ad2ae4d..ff1076c 100755 --- a/ue3/mycpu/test/test.sh +++ b/ue3/mycpu/test/test.sh | |||
| @@ -32,9 +32,11 @@ do | |||
| 32 | if [ "$md5_1" != "$md5_2" ] | 32 | if [ "$md5_1" != "$md5_2" ] |
| 33 | then | 33 | then |
| 34 | echo " ERROR: output and $reffile differ" | 34 | echo " ERROR: output and $reffile differ" |
| 35 | diff -Nau $reffile $tmpfile | 35 | diff -Naur "$reffile" "$tmpfile" |
| 36 | rm -rf "$tmpfile" | ||
| 36 | exit 1 | 37 | exit 1 |
| 37 | else | 38 | else |
| 38 | echo " SUCCESS" | 39 | echo " SUCCESS" |
| 39 | fi | 40 | fi |
| 41 | rm -rf "$tmpfile" | ||
| 40 | done | 42 | done |
