Question: Problem 1 Consider the piece of ARM Cortex MO+ assembly code given below and answer the following questions: mw 1.AGAIN CMP RO, #10 BLE LESSEQUAL

 Problem 1 Consider the piece of ARM Cortex MO+ assembly code

Problem 1 Consider the piece of ARM Cortex MO+ assembly code given below and answer the following questions: mw 1.AGAIN CMP RO, #10 BLE LESSEQUAL MOVS RO, #0 B DONE LESSEQUAL ADDS RO, RO, R1 B AGAIN 5. DONE 1. Assume RO is initialized with the value 20, what is the value of RO when the code above completes execution? How many times is Instruction 5 executed? Assume RO is initialized with the value o, and R1 with the value 1, how many times is Instruction 4 executed? 3. Assume now that RO is initialized with the value 0 and R1 with the value 2, how many times is instruction 4 executed? 4. What happens when RO is a decimal digit between 0 and 9 but R1 is initialized with the zero value? 5. What instructions would you add and where to prevent the above code from entering into an infinite loop

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!