ECE243 Practice Question Website


Main Assembly Programming Input/Output Memory Computer Architecture Advanced Topics

Computer Architecture Questions





Question 5

This question assumes the machine architecture at the right. Note the stack pointer register, SP, is not part of the register file. SEL is a multiplexor used to select one of the inputs to the ALU.
Assume memory addresses require only one memory cycle to fetch or store (unlike the 68000). Bus Architechture

Show the machine code control sequence of an instruction that will set a block of from 1 to 127 memory locations to zero. The size of the block is in R0 and the address of the block is in R1. Assume the instruction fetch sequence is the same as in Question 4 and start with the next step. R0 and R1 can change in the execution of the sequence.

Answer

  1. Sel0, And, MDRin
  2. WMFC, R1out, MARin, WRITE, Yin
  3. Sel1, Add, Zin, R0out, Yin
  4. Zout, R1in, MARin, Sel1, Sub, Zin, IF Zero END else Goto step 6