Write an assembly language program for the marie processor


Assignment:

Q: Design and write an assembly language program for the MARIE processor that counts the number of occurrences of a particular word value in an array of words.

The program must perform the required function and must satisfy the following requirements.

a) The first instruction of the program must be placed at location (address) 0x100 (100 hexadecimal) in MARIE's memory.

b) Use constant data values (One, Words, Key, and Base) that should not be changed by the program. The program can load from these memory locations, but should not store to them. The array of word values that are to be processed by the program should be in successive memory locations beginning at location Array. The program should not change any of the data values in the array. These values should all be "hard-coded" into the program. Ensure that you set the value in location Base depending on where the assembler places the array, as indicated in the listing file.

c) The program should work for any value in location Words and Key and for any set of values in the array of words, not just those provided in your solution, so test the program thoroughly with different values. The value in location Words must be greater than or equal to 1.

d) The program must place the final value for the count of matching words in location Match.

e) The program must use a loop and indirect addressing to access the values in the array of words. Use meaningful loop variables names like Ptr, Cnt, and Match in the loop.

f) The program should always initialize the values for Cnt, Ptr, and Match in the working data memory and not rely on the values for these locations that are defined in the assembly source file.

Solution Preview :

Prepared by a verified Expert
Computer Engineering: Write an assembly language program for the marie processor
Reference No:- TGS01939278

Now Priced at $25 (50% Discount)

Recommended (96%)

Rated (4.8/5)