Question: Write and execute a program in RV 3 2 - I assembly language to use a function to perform division by repeated subtraction. Use subroutine

Write and execute a program in RV32-I assembly language to use a function to perform division by repeated subtraction. Use subroutine div: for repeated subtraction.
Ex: 15/3=5
Perform the repeated subtractions until the numerator is greater than or equal to the denominator. The quotient is the no.of subtractions.
15-3=12(1st subtraction)
12-3=9(2nd subtraction)
9-3=6(3rd subtraction)
6-3=3(4th subtraction)
3-3=0(5th subtraction)

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 Programming Questions!