Computer architecture
Von Neumann architecture
- Early computers were fed data while the machines were actually running; it wasn’t possible to
store programs or data, which meant they couldn’t operate without considerable human
intervention.
- In 1945, John von Neumann developed the concept of the ‘stored program computer’, which
has been the basis of computer architecture ever since.
- Von Neumann architecture is based on the stored-program computer concept, where
instruction data and program data are stored in the same memory.
- His computer architecture design consists of a Control Unit, Arithmetic and Logic Unit (ALU),
Memory Unit, Registers and Inputs/Outputs.
The von Neumann architecture had the following main features:
• the concept of a central processing unit (CPU or processor)
• the CPU was able to access the memory directly
• computer memories could store programs as well as data
• stored programs were made up of instructions which could be executed in sequential order.
Central Processing Unit (CPU)
- The CPU has the responsibility for the execution or processing of all the instructions and data in a
computer application.
- It is sometimes referred to as the microprocessor or processor.
- The CPU contains the ALU, CU and a variety of registers.
Components of the central processing unit (CPU)
- The main components of the CPU are the Control Unit (CU), Arithmetic & Logic Unit (ALU) and system
clock.
Registers
• Registers are high speed storage areas in the CPU. All data must be stored in a register before it can be
processed.
Arithmetic & Logic Unit (ALU)
• The ALU allows arithmetic (add, subtract etc.) and logic (AND, OR, NOT etc.) operations to be carried out.
Control Unit (CU)
• The control unit controls the operation of the computer’s ALU, memory and input/output devices, telling
them how to respond to the program instructions it has just read and interpreted from the memory unit.
• The control unit also provides the timing and control signals through the system clock.
• The System clock - is used to produce timing signals on the control bus to ensure this vital synchronisation
takes place – without the clock the computer would simply crash!
Buses
• Buses are the means by which data is transmitted from one part of a computer to another, connecting all
major internal components to the CPU and memory.
• A standard CPU system bus is comprised of a control bus, data bus and address bus.
Memory Unit
- The memory unit consists of RAM, sometimes referred to as primary or main memory. Unlike a hard drive
(secondary memory), this memory is fast and also directly accessible by the CPU.
- The RAM holds all the data and programs needed to be accessed by the CPU. The RAM is often referred
to as the Immediate Access Store (IAS).
- Loading data from permanent memory (hard drive), into the faster and directly accessible temporary
memory (RAM), allows the CPU to operate much quicker
Fetch–Decode–Execute cycle
Fetch–Decode–Execute cycle
• The fetch execute cycle is the basic operation (instruction) cycle of a computer (also known as the fetch
decode execute cycle).
• During the fetch execute cycle, the computer retrieves a program instruction from its memory. It then
establishes and carries out the actions that are required for that instruction.
• The cycle of fetching, decoding, and executing an instruction is continually repeated by the CPU whilst
the computer is turned on.
Fetch
• In the Fetch–Decode–Execute cycle, the next instruction is fetched from the memory address currently
stored in the MAR and the instruction is stored in the MDR.
• The contents of the MDR are then copied to the Current Instruction Register (CIR).
• The PC is then incremented (increased by 1) so that the next instruction can be then be processed.
Decode
• The instruction is then decoded so that it can be interpreted in the next part of the cycle.
Execute
• The CPU 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.
Factors that determine the performance of a CPU:
1 System Clock
- The first thing to consider is the role of the system clock.
- The clock defines the clock cycle that synchronises all computer operations.
- By increasing clock speed, the processing speed of the computer is also increased (a typical current
value is 3.5 GHz – which means 3.5 billion clock cycles a second).
2 The width of the address bus and data bus can also affect computer performance
3 Overclocking - The clock speed can be changed by accessing the BIOS (Basic Input/Output System) and
altering the settings.
• However, using a clock speed higher than the computer was designed for can lead to problems, for
example:
i execution of instructions outside design limits can lead to seriously unsynchronised operations (i.e. an
instruction is unable to complete in time before the next one is due to be executed) – the computer would
frequently crash and become unstable
ii overclocking can lead to serious overheating of the CPU again leading to unreliable performance.
3 The use of cache memories can also improve CPU performance.
- Cache memory stores frequently used instructions and data that need to be accessed faster, which
improves CPU performance. When a CPU wishes to read memory, it will first check out the cache and then
move on to main memory/RAM if the required data isn’t there. The larger the cache memory size the better
the CPU performance.
4 The use of a different number of cores can improve computer performance.
• One core is made up of an ALU, a control unit and the registers. Many computers are dual core (the CPU
is made up of two cores) or quad core (the CPU is made up of four cores). The idea of using more cores
alleviates the need to continually increase clock speeds. However, doubling the number of cores doesn’t
necessarily double the computer’s performance since we have to take into account the need for the
CPU to communicate with each core; this will reduce overall performance.