Computer Science Notes
Paper 1 - Computer Systems
1.1 Systems architecture
1.1.1 Architecture of the CPU
CPU
CPU is the Central Processing Unit. Its purpose is to carry out a set of instructions that is
contained in a computer program
CPU contains the following:
Arithmetic Logic Unit (ALU): Carries out the calculations and logical decisions required by
the program instructions the CPU is processing
Control Unit (CU): The circuits coordinating the activities of the CPU. It sends out control
signals to control how data moves around the parts of the CPU and memory.
Registers: Quick small stores of data within the CPU that can be accessed very quickly.
Cache: Most frequently used instructions are copied here to reduce the time needed to fetch
instructions from the RAM.
The CPU operates at high speeds governed by a clock chip
The fetch-execute cycle
Fetch:
The address of the next instruction is fetched and placed in the MAR
The PC is incremented to point to the next instruction that will be needed when the cycle
starts again
The instruction stored at the location held by the MAR is copied to the MDR
Decode:
The instruction is decoded by the CU
It checks the instructions and works out what needs to be done.
Execute:
The decoded instruction is then executed, such as performing a calculation using the ALU,
locating some data in memory, changing the PC value
The process is then repeated
,Von Neumann Architecture
In Von Neumann Architecture, data and instructions are stored in the same memory
Accumulator (ACC) stores the results of any calculations made by the ALU and the values
of inputs and outputs to and from the CPU
Program counter (PC) holds the memory address (location) of the next instruction to be
performed by the CPU
Memory data register (MDR) stores data fetched from memory or any data that is to be
transferred to and stored in memory
Memory address register (MAR) stores the memory address of the data to be fetched from
or to be stored.
1.1.2 CPU performance
Clock speed
The CPU is constantly fetching and executing instructions and the speed at which it does
this is determined by an electronic clock.
The faster the clock speed, the more instructions can be executed every second
The clock speed is measured in Hz
Cache size
Cache used to hold data that needs to be accessed very quickly.
Accessing cache memory is much faster than accessing RAM.
The more data that can be stored in cache memory rather than RAM, the faster and more
efficient the process.
The more cache memory available, the better the performance of the computer
Number of cores
In a multi-core CPU there are a number of processor cores each capable of carrying out the
fetch-execute cycle
If the program supports multi-cores, the CPU can handle several instructions at the same
time
, 1.1.3 Embedded systems
An embedded system is a computer system that has been designed for a single, dedicated
function, inside a larger mechanical unit
They are designed and engineered to perform a limited set of tasks to reduce size and
improve performance.
A laptop/desktop/smartphone is a non-embedded system
Embedded systems have the following characteristics: Low power, small size, rugged, low
cost, dedicated software
Examples of embedded systems are washing machines, televisions, microwaves, Sat navs,
smart toilet
Paper 1 - Computer Systems
1.1 Systems architecture
1.1.1 Architecture of the CPU
CPU
CPU is the Central Processing Unit. Its purpose is to carry out a set of instructions that is
contained in a computer program
CPU contains the following:
Arithmetic Logic Unit (ALU): Carries out the calculations and logical decisions required by
the program instructions the CPU is processing
Control Unit (CU): The circuits coordinating the activities of the CPU. It sends out control
signals to control how data moves around the parts of the CPU and memory.
Registers: Quick small stores of data within the CPU that can be accessed very quickly.
Cache: Most frequently used instructions are copied here to reduce the time needed to fetch
instructions from the RAM.
The CPU operates at high speeds governed by a clock chip
The fetch-execute cycle
Fetch:
The address of the next instruction is fetched and placed in the MAR
The PC is incremented to point to the next instruction that will be needed when the cycle
starts again
The instruction stored at the location held by the MAR is copied to the MDR
Decode:
The instruction is decoded by the CU
It checks the instructions and works out what needs to be done.
Execute:
The decoded instruction is then executed, such as performing a calculation using the ALU,
locating some data in memory, changing the PC value
The process is then repeated
,Von Neumann Architecture
In Von Neumann Architecture, data and instructions are stored in the same memory
Accumulator (ACC) stores the results of any calculations made by the ALU and the values
of inputs and outputs to and from the CPU
Program counter (PC) holds the memory address (location) of the next instruction to be
performed by the CPU
Memory data register (MDR) stores data fetched from memory or any data that is to be
transferred to and stored in memory
Memory address register (MAR) stores the memory address of the data to be fetched from
or to be stored.
1.1.2 CPU performance
Clock speed
The CPU is constantly fetching and executing instructions and the speed at which it does
this is determined by an electronic clock.
The faster the clock speed, the more instructions can be executed every second
The clock speed is measured in Hz
Cache size
Cache used to hold data that needs to be accessed very quickly.
Accessing cache memory is much faster than accessing RAM.
The more data that can be stored in cache memory rather than RAM, the faster and more
efficient the process.
The more cache memory available, the better the performance of the computer
Number of cores
In a multi-core CPU there are a number of processor cores each capable of carrying out the
fetch-execute cycle
If the program supports multi-cores, the CPU can handle several instructions at the same
time
, 1.1.3 Embedded systems
An embedded system is a computer system that has been designed for a single, dedicated
function, inside a larger mechanical unit
They are designed and engineered to perform a limited set of tasks to reduce size and
improve performance.
A laptop/desktop/smartphone is a non-embedded system
Embedded systems have the following characteristics: Low power, small size, rugged, low
cost, dedicated software
Examples of embedded systems are washing machines, televisions, microwaves, Sat navs,
smart toilet