Presentation is loading. Please wait.

Presentation is loading. Please wait.

Review.

Similar presentations


Presentation on theme: "Review."— Presentation transcript:

1 Review

2 MIPS Program Data Segment Text Segment
# an example of iteration to compute the sum of every other word .data start: .word 1, 0, 1, 0, 1, 0, 1, 0 .word 1, 0, 1, 0, 1, 0, 1, 0 .text .globl main main: la $t0, start #load start address of array addi $t1, $t0,128 # address of end of array of 64 words add $t2, $zero, $zero #initialize sum loop: lw $t3, 0($t0) #fetch array element add $t2, $t2, $t3 # update sum addi $t0, $t0, 8 # point to next address bne $t1, $t0, loop # if not done, start next iteration li $v0, 10 #load program termination code syscall Data Segment Text Segment Check the class resources page for link to QtSpim simulator

3 ECE 2020 Datapath X Y Sample problems at


Download ppt "Review."

Similar presentations


Ads by Google