You are on page 1of 8

Computer architecture and fetch

execute cycle

Operating system:
● OS is essentially software running in the background of a
computer system.
● It manages many of the basic functions like ,multitasking,
error handling and input output
● Without it most of the computers would be very
user-unfriendly and the majority of the users would find it
almost impossible to work with computers.
● Example of OS are : Windows, Android , IOS and etc

Interrupts and buffer:


● An ​interrupt ​is a signal sent from a device or from software
to the processor
● This will cause the processor to temporarily stop
● Interrupts can occur when for example
1. A disk drive is ready to receive more data
2. An error has occurred
3. a software error has occurred
● It allows computers to carry out many task at same time
● Buffers ​are used in computers as a temporary memory area
● These are essential in
● modern computers since hardware devices operate at much
slower speed than the processor.
● Buffers are essentially filled from the processor or memory
unit and whilst these are emptied to the hardware device, the
processor carries on with other tasks
● Buffers are used for example streaming a video on internet
● Buffers and interrupts are often used together to allow
standard computer functions to be carried out. These
functions are often taken for granted by users of modern
computer systems

This image shows how buffers and interrupts are used when
a document is sent to the printer.

Computer Architecture:
● John von Neumann developed the idea of a stored program
computer, often referred to as the von Neumann architecture
concept in which his idea was to hold programs and data in
a memory, data would then move between the memory unit
and the processor

This image shows von neumann computer model

Type of buses :

● The idea of Addresses and Registers are that:


● Addresses are used to indicate where data is stored
● Registers are needed so that data can be manipulated
within the computer

● Each address in the memory is unique


● A register is simply a high speed storage area within the
computer.

Memory Unit:
● The computer memory unit is made up of a number of
partitions,each partition consists of an ​Address ​and its
contents
● The address will uniquely identify every location in the
memory and the contents will be the binary.

Examples of Registers:
● MAR (memory address register)
● MDR (memory data register)
● ALU (arithmetic logic unit)
● PC(program counter)
● CIR (current instruction register)

How two registers(MAR and MDR) shown in the memory unit


are used

Read Operation:

We will use the memory section shown in the following table

1. We want to read contents of memory location 1111 0001


2. The address of location 1111 0001 to be read from is first
written into the MAR
3. A read signal is sent to the computer memory using the
control bus
4. The contents of memory location 1111 0001 are then put
into the MDR

Write Operation:
We will again use the memory section of the table
1. This time we want to show how the value 1001 0101 was
written into memory location 1111 1101
2. The data to be stored is first written into the MDR
3. This data has to be written into the memory location with the
address 1111 1101 sot his address is now written into the
MAR
4. Finally a write signal is sent to the computer memory using
the control bus this value will then be written into the correct
memory location

Processor:
● It contains the ALU
● The ALU allow arithmetic and logic operations to be carried
out
● For example addition and subtraction

Control Unit:
● The control unit controls the operation of the memory,
processor and input output devices
● It contains the CIR and PC
● The CIR (current instruction register) contains the
current instruction during processing
● The PC (program counter) contains the address of the
next instruction to be executed
● Essentially the Control unit reads an instruction from the
memory the address of location where the instruction can be
found is stored in the program counter (pc).
● During that process the signals are generated along the
control bus to tell the other components in the computer
what to do.

The Fetch and execute cycle:


● To carry out the set of instructions the processor first
srtches some data and instruction from the memory and
stores them in suitable registers.
● Both the address bus and the data bus are used in this
process once this is done each instruction needs to be
decoded before finally being executed.This is known as fetch
execute cycle

Fetch:
● The next instruction is fetched from the memory
address currently stored in the program counter (PC)
and is then stored in the current instruction register
(CIR).
● The PC is then incremented (increased by 1) so that
next instruction could be processed
● This is then decoded so that each instruction can be
interpreted in the next part of the cycle.

Execute:

● The processor passes the decoded instruction as a set of


control signals to the appropriate components within the
computer system
● This allows each instruction to be carried out in its logical
sequence
Shows the Fetch execute cycle

You might also like