project2MIPS - syscall li $v0, 4 la $a0, Str1 syscall...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Sheet1 Page 1 .data fib1:.word 0 fib2:.word 0 startnum:.word 0 savenum:.word 0 gofib:.word 0 total:.word 0 count: .word 0 Str1:.asciiz"\n" .text . #Store Values .text . li $t0, 1 sw $t0, fib1 li $t1, 1 sw $t1, fib2 li $t2, 0 sw $t2, gofib li $t3, 7 sw $t3, total li $t4, 0 sw $t4, count li $t5, 1 sw $t5, startnum li $t6, 1 sw $t6, savenum #Print out the first part li $v0, 1 lw $a0, fib1
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: syscall li $v0, 4 la $a0, Str1 syscall li$v0, 1 lw$a0, fib2 syscall li $v0, 4 la $a0, Str1 syscall s loop: bgt$t4,$t3, done add $t2, $t5, $t6 sw $t2, gofib li$v0, 1 lw$a0, gofib syscall li$v0, 4 Sheet1 Page 2 la$a0, Str1 syscall move $t6, $t5 move $t5, $t2 addi$t4, $t4, 1 j loop done: li$v0, 10 syscall...
View Full Document

This note was uploaded on 04/17/2008 for the course CS 312 taught by Professor Mcdowell during the Spring '08 term at Rhode Island College.

Page1 / 2

project2MIPS - syscall li $v0, 4 la $a0, Str1 syscall...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online