问题描述
- 简单的MIPS汇编,error:invalid program counter value:0
-
.data 0x10000000
.textmain:
addu $s7,$ra,$0
li $v0,5
syscalladdi $a0,$v0,0
j fact
li $v0,1
syscalladdu $ra,$0,$s7
jr $rafact:
addi $sp,$sp,-8
sw $ra,4($sp)
sw $a0,0($sp)
slti $t0,$a0,1
beq $t0,$zero,exit1
addi $v1,$0,1 #return 1
addi $sp,$sp,8
jr $raexit1:
addi $a0,$a0,-1
jal fact
lw $a0,0($sp)
lw $ra,4($sp)
addi $sp,$sp,8
mul $v1,$v1,$a0
jr $ra做一个n!递归,请问错在哪里呢,求教
时间: 2025-01-07 13:49:53