Question: Please write a MIPS program. A shell program is pasted below as a template/starting point. # This program computes the index at which the maximum

Please write a MIPS program. A shell program is pasted below as a template/starting point.

Please write a MIPS program. A shell program is pasted below as

# This program computes the index at which the maximum value occurs in a

# set of 10 confidence values and stores it at the memory location labeled ClassID.

# If there are two or more indices that have equal maximum values, the LARGER

# index is chosen.

.data

# DO NOT change the following three labels (you may change the initial values):

ConfidenceValues: .word 1, 70, 0, 0, 21, 2, 3, 0, 3, 0

ClassID: .alloc 1

.text

# write your code here...

jr $31 # return to OS

HW1-3: The goal of this part is for you to install MiSaSiM, modify a short assembly program HW1-3-shell.asm, simulate, test and debug it in MiSaSiM. The MiSaSiM simulator can be installed according to the instructions at http://lindawills.ece.gatech.edu/misasim Copy or rename the shell program to HW1-3.asm and modify it to compute the index of the largest integer in the 10 element array whose base is labelled ConfidenceValues. Store the index in the location labeled ClassID. If there are two or more integers with equal maximum value, store the highest index at which the max value occurs. The array contains exactly 10 unsigned integers. Be sure to try multiple test cases by changing the initial values in the array

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!