fetch-execute cycle. memory read operation read from memory

Post on 29-Mar-2015

225 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Fetch-Execute cycle

Memory Read operation

Read from memory

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC1

The Program Counter (PC) holds the address of the next instruction

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC1

The contents of the PC are copied to the Memory Address Register (MAR)

10110111

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC1

Memory address to be accessed is placed onto the address bus

10110111

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC1

The control bus sends a read signal

>>read>>

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC1

The contents of the memory location are passed along the data bus to the Memory Data Register (MDR)

01010111

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC1

The PC is incremented ready for the next instruction

2

Memory Write operation

Write to memory

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC2

Data is placed onto the data bus

1110011

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC2

Memory address to be written to is placed onto the address bus

11110010

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC2

A ‘write’ signal is sent along the control bus

>>write>>

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC2

The data is transferred to the destination in memory

10111110

MainMemory

MAR

MDR

ControlUnit

ALU

Otherregisters

ElectronicClock

Clock pulses

Address bus

Data bus

Control bus

PC2

The PC is incremented

3

top related