This commit is contained in:
施羿廷
2024-10-04 19:53:08 +00:00
committed by Yi-Ting Shih
parent fe65d46df7
commit b582884995
19 changed files with 389 additions and 189 deletions

View File

@@ -158,6 +158,13 @@ clean:
distclean: clean
$(RM) -f $(PROGRAMS)
run: $(PROGRAMS)
for i in $(PROGRAMS); do \
echo ===== $$i =====; \
$(NACHOS) -e $$i; \
done
unknownhost:
@echo Host type could not be determined.
@echo make is terminating.

View File

@@ -1,12 +1,9 @@
#include "syscall.h"
int
main()
{
int n;
for (n=9;n>5;n--) {
int main() {
int n;
for (n = 9; n > 5; n--)
PrintInt(n);
}
Halt();
Halt();
}

1
code/test/file1.test Normal file
View File

@@ -0,0 +1 @@
abcdefghijklmnopqrstuvwxyz

2
code/test/os_students.sh Normal file
View File

@@ -0,0 +1,2 @@
make clean
make run

View File

@@ -186,6 +186,14 @@ ThreadJoin:
j $31
.end ThreadJoin
.globl PrintInt
.ent PrintInt
PrintInt:
addiu $2,$0,SC_PrintInt
syscall
j $31
.end PrintInt
/* dummy function to keep gcc happy */
.globl __main