Question: Write in assembly code ASSIGNMENT Write a program to compute the product of a 3-byte number (multiplicand) stored at memory locations 00-$02 and a 1-byte
ASSIGNMENT Write a program to compute the product of a 3-byte number (multiplicand) stored at memory locations 00-$02 and a 1-byte number (multiplier) stored at memory location $03. Save the 4-byte product at memory locations $04-$07 The multiplication can be carried out in the following manner: MSB MID LSB xx XX XMultiplicand XX Multiplier MSB LSB xX P1 MSB LSB P2 MSB LSB P3 MSB MID-H MID-L LSB xx x Product The steps of the above algorithm can be summarized as follows: 1 Allocate memory (3 bytes) for multiplicand M 2) Allocate memory (1 byte) for multiplier N 3) Allocate memory (4 bytes) for product P )Allocate memory (2 bytes) for P1 5) Allocate memory (2 bytes) for P2 6) Allocate memory (2 bytes) for P3 7) Read Multiplicand LSB to accumulator A (ACCA) 8) Read Multiplier to accumulator B (ACCB) ASSIGNMENT Write a program to compute the product of a 3-byte number (multiplicand) stored at memory locations 00-$02 and a 1-byte number (multiplier) stored at memory location $03. Save the 4-byte product at memory locations $04-$07 The multiplication can be carried out in the following manner: MSB MID LSB xx XX XMultiplicand XX Multiplier MSB LSB xX P1 MSB LSB P2 MSB LSB P3 MSB MID-H MID-L LSB xx x Product The steps of the above algorithm can be summarized as follows: 1 Allocate memory (3 bytes) for multiplicand M 2) Allocate memory (1 byte) for multiplier N 3) Allocate memory (4 bytes) for product P )Allocate memory (2 bytes) for P1 5) Allocate memory (2 bytes) for P2 6) Allocate memory (2 bytes) for P3 7) Read Multiplicand LSB to accumulator A (ACCA) 8) Read Multiplier to accumulator B (ACCB)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
