Question: Please help writting the part for finding the largest number in a list of integers. The code has to be assembly langauage. Thank you Implement
Please help writting the part for finding the largest number in a list of integers. The code has to be assembly langauage. Thank you 
Implement a subroutine by using the program in assignment one so that it becomes a subroutine. The sub- routine, LARGE, has to find the largest number in a list. The main program passes the number of entries and the address of the start of the list as parameters to the subroutine via registers r4 and r5. The subroutine returns the value of the largest number to the calling program via register r2. A suitable main program is given for use. Program that finds the largest number in a list of integers k/ text global start Start: movia r8, RESULT r8 points to the result location r4 holds number of elements in the list ldw r4, 4(r8) addi r5, r8, 8 r5 points to the start of the list call LARGE r2 holds the subroutine return value stw r2, (r8) STOP: br STOP LARGE: RESULT skip word NUMBERS word 4, 5, 3, 6 .word 1, 8, 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
