.text LF0_TIGERATS_fib: addi \$sp, \$sp, -4 sw \$fp, 0(\$sp) move \$fp, \$sp L4_TIGERATS: move \$v0, \$a0 sw \$a1, 8(\$fp) move \$a2, \$zero move \$a3, \$zero li \$a0, 1 li \$a1, 2 L0_TIGERATS: bgt \$a1, \$v0, L2_TIGERATS L1_TIGERATS: addi \$a1, \$a1, 1 add \$a2, \$a3, \$a0 move \$a3, \$a0 move \$a0, \$a2 j L0_TIGERATS L2_TIGERATS: move \$v0, \$a0 j L3_TIGERATS L3_TIGERATS: move \$sp, \$fp lw \$fp, 0(\$sp) addi \$sp, \$sp, 4 jr \$ra .data LC0_TIGERATS: .asciiz "fib (10) = " .data LC1_TIGERATS: .asciiz "\n" .text .globl tiger_main tiger_main: addi \$sp, \$sp, -4 sw \$fp, 0(\$sp) move \$fp, \$sp addi \$sp, \$sp, -4 L6_TIGERATS: sw \$ra, -4(\$fp) addi \$sp, \$sp, -4 la \$a0, LC0_TIGERATS jal tiger_print addi \$sp, \$sp, 4 addi \$sp, \$sp, -8 li \$a0, 10 move \$a1, \$fp jal LF0_TIGERATS_fib addi \$sp, \$sp, 8 move \$a0, \$v0 addi \$sp, \$sp, -4 jal tiger_print_int addi \$sp, \$sp, 4 addi \$sp, \$sp, -4 la \$a0, LC1_TIGERATS jal tiger_print addi \$sp, \$sp, 4 lw \$ra, -4(\$fp) j L5_TIGERATS L5_TIGERATS: move \$sp, \$fp lw \$fp, 0(\$sp) addi \$sp, \$sp, 4 jr \$ra