Mapa mental
CPU and Performance
Conteúdo do mapa
CPU and Performance
Von Neumann Architecture
- Used the idea of holding both programs and data in memory
- Data would move between the memory unit and the processor
- Describes a system where the CPU runs programs stored in memory
CPU components
- The CPU is hardware that executes programs and manages the rest of the hardware
- Memory
- Holds the program instructions and the program data
- Registers
- Typical size of 32 or 64 bits
- Even smaller and faster than cache
- Memory locations within the CPU to temporarily store memory addresses, instructions, or data
- Control unit (CU)
- Coordinates all of the CPU's actions in the fetch decode execute cycle
- Controls the execution of instructions in the correct sequence
- Decodes instructions
- Regulates and controls processor timing using regular pulses from the system clock
- Sends and receives control signals to and from other devices within a computer
- Program counter (PC)
- Type of register
- A register which holds the memory address of the next instruction to be processed
- Cache
- Very fast memory close ti the CPU used to temporarily hold data or instructions that are likely to be needed again by the processor in the course of running a program
- Memory address register (MAR)
- Type of register
- Holds the address (location in memory) of the current instruction or piece of data to be fetched or stored
- Memory data register (MDR)
- Type of register
- Holds data or a program instruction when it is fetched from memory or data that is waiting to be written to memory
- Accumulator (ACC)
- Type of register
- Stores intermediate results of calculations in the ALU
- Arithmetic logic unit (ALU)
- Carries out mathematical and logical operations including AND NOT OR and binary shifts (shift operations) and arithmetic operations ( + - divide x )
Fetch decode execute cycle
- The processor fetches an instruction, decodes it, then executes it. The processor executes one instruction at a time.
- Fetch
- 1) Copy the memory address from the PC to the MAR
- 2) Copy the instructions stored in the MAR address to the MAR
- 3) Increment (increase) the PC to point the address of the next instruction, ready for the next cycle
- Decode
- The instruction in the MDR is decoded by the control unit. The CU may then prepare for the next step, e.g. loading values into the MAR or MDR
- Execute
- The instruction is performed. This could be load data from memory, write data to memory, do a calculation or logic operation (using ALU), change the address in the PC,or halt the program
The CPU
- The CPU is hardware (a physical part of the computer)
- Most important piece of hardware as it does all the processing
- Processes all the data and instructions that make the system work
- The processing power of the CPU depends on the clock speed, number of cores, and cache size
- Executes instructions stored in memory by repeatedly carrying out the FDE cycle
- Main parts
- Control unit
- In overall control of the CPU
- The main job is to manage the FDE cycle
- Controls the flow of data inside the CPU to registers, ALU, cache, and outside of the CPU, to main memory, input/output devices
- Regulates and controls processor timing using regular pulses from the system clock
- Sends and receives control signals to and from other devices within the computer
- Arithmetic Logic Unit
- Does the calculations
- Completes + and -
- Compares sizes of numbers
- Completes x and / by repeatedly carrying out + and -
- Performs logic operations (AND OR NOT)
- Performs binary shifts
- Contains accumulator
- Cache
- Very fast memory in the CPU
- Slower than registers, faster than RAM
- Stores regularly used data so the CPU can access the data quickly the next time that it is needed
- CPU checks cache when it requests data and if it isn't there it goes to RAM
- Low capacity and expensive compared to RAM and secondary storage
- Different levels of cache
- L1 - quickest but holds the least L2 - slower but holds more L3 - slowest but holds the most
- Control unit
Registers
- Hold tiny bits of data needed by the CPU temporarily
- Super quick to read/write to
- Much quicker than any form of memory
- PC, MDR, MAR, ACC
Factors affecting CPU performance
- Number of cores
- Multiple cores could work on different programs that operate in parallel, but unless the computer is designed to use multiple cores, a quad core processor isn't always four times faster
- Dual core processor has two processing units within the CPU, quad core has four
- Parallel processing can take place (two instructions being executed simultaneously)
- Two cores does not always mean the computer can perform twice as many operations per second
- More cores will operate faster than a single core
- Cache
- More costly but faster memory where frequently used instructions or data can be stored temporarily
- More cache increases CPU performance
- If information is not in cache, it has to be fetched from RAM
- Typical PCs may have 8 or 16GB of RAM (main memory) but only 2MB of cache
- The more cache memory a computer has, the more data and instructions can be held in cache and made available more quickly, improving processor performance
- Clock speed
- Speed at which a processor operates
- Measured in Hz hertz, the number of cycles per second
- 1Ghz means 1 billion cycles per second
- The faster the clock speed, the more instructions fetches, decoded, executed in a second
- Typical PC speeds - 2-4 GHz
- Greater clock speed, the faster the instructions will be executed
- 4GHz is not always as fast as 2GHz
- There are other factors that affect CPU performance such as cache and number of cores
- Some CPUs can be overclocked making them run at a higher clock speed than factory set rate.. This can make CPUs overheat, cause crashes, cause permanent damage to the system. High performance cooling systems are usually needed.
- Questions
- How many cycles is a 4.5GHz dual core processor theoretically able to perform per second?
- 4.5 GHz is 4.5 billion 4.5 billion x 2 = 9 billion
- Why may a computer with a dual core processor not be able to be twice as fast as a single core processor with the same clock speed
- The software running on the computer may not be written to make the most efficient use of multiple cores
- Additional cores may be redundant if software is only written for one core or if the output of one operation is needed for the next so they can' be performed simultaneously
- Cache is also a factor that affects the CPU performance
- How many cycles is a 4.5GHz dual core processor theoretically able to perform per second?
- Number of cores
Informações
- Descrição
- GCSE Computer Studies Mapa Mental sobre CPU and Performance, criado por Izzy DB em 20-12-2021.
- Criado por
- Izzy DB
- Visualizações
- 0
- Avaliação