Memory address register (MAR)

Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.

Memory address register (MAR)

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. What does the MAR hold?
A The address of the memory location about to be read from or written to
B The data or instruction that has just been fetched from memory
2. During the fetch stage, where does the MAR get its address from?
A The arithmetic logic unit (ALU)
B The program counter (PC)
3. Which bus carries the address from the MAR to the RAM?
A Address bus
B Data bus
4. True or false: the MAR stores the instruction that is being executed.
A False: the MAR stores an address, not an instruction
B True: the MAR stores the current instruction
5. The MAR contains the value 0100. What does 0100 represent?
A The data that will be stored in the accumulator
B The location in RAM that will be accessed

Match the Pairs

Draw a line connecting each item on the left to its match on the right.

Left columnRight column
1MAR AMAR = 0042 (address)
2MAR ← PC BThe address is sent along the address bus. The data bus carries data and instructions between the CPU and RAM.
3The MAR sends the address it holds along the address bus to RAM CMAR → address bus → RAM
4The MAR holds an address, not data, so it stores a memory location such as 0042 DThe address in the program counter is copied into the MAR so the CPU knows which memory location to read next
5The MAR holds the instruction fetched from RAM EThe MAR holds an address, not an instruction. The fetched instruction or data is held in the MDR.
6MAR sends the address along the data bus FThe Memory Address Register, which holds the address of the memory location about to be read from or written to

Definitions

MAR

Fill in the Blanks

Complete each line of code by filling in the missing parts.

1.
MAR ← __
2.
___ ← PC
3.
SEND MAR ON THE _______ BUS
4.
// MAR holds an _______, not data
5.
MAR ← PC MDR ← RAM[___]

Spot the Error

Shade in the letter of the line that contains an error.

Question 1
A MAR ← MDR
B SEND MAR ON ADDRESS BUS
C MDR ← RAM[MAR]
Question 2
A PC ← 100
B MAR ← CIR
C SEND MAR ON ADDRESS BUS
Question 3
A MAR holds data
B MDR holds data
C RAM[MAR] gives the data
Question 4
A PC ← 5
B MAR ← PC
C SEND MAR ON DATA BUS
Question 5
A MAR ← PC
B SEND MAR ON ADDRESS BUS
C MAR ← RAM[MAR]

Answer Key

Memory address register (MAR)
Section A: Quick Questions
Q1
A — The address of the memory location about to be read from or written to
Q2
B — The program counter (PC)
Q3
A — Address bus
Q4
A — False: the MAR stores an address, not an instruction
Q5
B — The location in RAM that will be accessed
Section B: Match the Pairs
Q1
MAR → The Memory Address Register, which holds the address of the memory location about to be read from or written to
Q2
MAR ← PC → The address in the program counter is copied into the MAR so the CPU knows which memory location to read next
Q3
The MAR sends the address it holds along the address bus to RAM → MAR → address bus → RAM
Q4
The MAR holds an address, not data, so it stores a memory location such as 0042 → MAR = 0042 (address)
Q5
The MAR holds the instruction fetched from RAM → The MAR holds an address, not an instruction. The fetched instruction or data is held in the MDR.
Q6
MAR sends the address along the data bus → The address is sent along the address bus. The data bus carries data and instructions between the CPU and RAM.
Section C: Definitions
Q1
MAR — Memory Address Register: a CPU register that holds the address of the memory location about to be read from or written to. It holds an address, not data, and sends it along the address bus.
Section D: Fill in the Blanks
Q1
MAR ← PC
Q2
MAR ← PC
Q3
SEND MAR ON THE ADDRESS BUS
Q4
// MAR holds an address, not data
Q5
MAR ← PC MDR ← RAM[MAR]
Section E: Spot the Error
Q1
A — The MAR receives the address of the next instruction from the PC. The MDR holds data, so it should not be copied into the MAR. It should be MAR ← PC.
Q2
B — During fetch the MAR gets its address from the PC. The CIR holds the current instruction, not an address to fetch from. It should be MAR ← PC.
Q3
A — The MAR holds the address of a memory location, not data. Data is held in the MDR. It should be: MAR holds an address.
Q4
C — The MAR's address is sent along the address bus. The data bus carries data. It should be SEND MAR ON ADDRESS BUS.
Q5
C — The data read from RAM goes into the MDR. The MAR only holds the address of the location being read. It should be MDR ← RAM[MAR].