# comments are delimited by hash marks
.data
silly_str: .asciiz "My first MIPS program\n"
.text
main:
li $v0, 4 # load the value "4" into register $v0
la $a0, silly_str # load the address of "silly_str" into register $a0
syscall # perform the "print_string" system call ($v0 = 4)
jr $ra # return to the calling procedure
以上是我试图在Mac上加载到SPIM的文件。每当我尝试加载它时,都会出现以下错误,并且我不确定是什么错误。
(spim) load "test.s"
Cannot open file: `test.s'
(spim) input in flex scanner failed
在此先感谢您的帮助。