Question: For lab 3 part 1, you will be loading and storing data. You will be given one world-length number in the data area of memory

For lab 3 part 1, you will be loading and storing data. You will be given one world-length number in the data area of memory that will start at the address labeled DATA. Load the address of the word in memory into r0 as shown in the given code. Load the entire word at the address into r1. Load the first (lowest significant digits) byte of the word into r2 and post index the address by 1 byte. Load the second byte of the word into r3 (using the updated address). Load the third byte of the word into r4 using pre-indexing with auto-increment. Load the fourth byte of the word into r5 using pre-indexing. Load the address of the spaces of memory into r6. Store the entire word at the address in r6. Then store the most significant byte of the word after this word in memory. View the memory contents after you execute the code.

Code Given:

ENTRY

LDR r0, =DATA ;Load address of DATA into r0

LDR r1, [r0] ;Load entire word at address r0 into r1

;Insert Code Here;

b stop

DATA DCD 0xABCD1234

NEW Fill 20

stop END

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!