我想了解有關$ ra,所以我想要的輸出是「mainfunction1main」,通過主要調用function1,function1返回到main,並完成主要。但由於某種原因,我得到一個無限循環打印「mainfunction1mainfunction1 ......」我做錯了什麼?無限循環簡單mips
.data
mainstring: .asciiz "main"
string1: .asciiz "function1"
string2: .asciiz "function2"
string3: .asciiz "function3"
.text
main: la $a0,mainstring
li $v0, 4
syscall
jal function1
la $a0, mainstring
syscall
function1: la $a0, string1
syscall
jr $ra