š¾ The CPU Flashcards
what does CPU stand for?
Central Processing Unit
ie. why is it important?
define the purpose of the CPU in a computer
- it is responsible for all of a computerās processing (like a brain)
all connect to the CPUā¦
What are the main components of a computer (there are 4)?
- Main memory
- input devices
- secondary storage
- output devices
what is the Von Neumann architecture?
A computer architecture model proposed by John von Neumann in the mid-20th century, which forms the basis for most modern computers.
what are the components of the Von Neumann architecture (there are 5)?
- CPU
- memory unit
- control unit
- ALU
- input/output devices
what are the registers in the CPU (there are 4)?
- program counter
- ALU
- Control unit
- General Purpose Registers
explain a program counter
A special purpose register that holds the address of the next instruction to be executed
explain the general purpose registers
- they hold data, such as numbers during arithmetic calculations
- Some architectures have just a single register called the Accumulator
where is the program counter located?
in the control unit
How does the program counter work?
- The Program Counter points
to the next instruction that
needs to be executed - The Program Counter is
incremented after fetching
an instruction - This moves it on to point to
the next instruction to be
executed
Explain the accumulator
- The accumulator is where
arithmetic and logic results are
temporarily stored much like the
M+ function on a calculator - Speeds up the storage and retrieval of calculations
Why is the accumulator important?
Without the accumulator, it would
be necessary to write the result of
each calculation to main memory (aka. Would take much longer and is a waste of time, so the accumulator does this long, boring job for us instead!)
What does ALU stand for?
Arithmetic Logic Unit
Explain the ALU (has 3 functions)
It performs:
1. Logical operations
2. Shift operations
3. Arithmetic operations
what are the two memory registers to implement the von Neumann architecture?
MAR and MDR
what does MAR stand for?
Memory Address Register
what are the (3 main) functions of the MAR?
- Holds the address of the current instruction being done
- knows the location of data that needs to be accessed
- keeps track of where data is located
what does MDR stand for?
Memory Data Register
what are the (2 main) functions of the MDR?
- Holds the actual data being stored in RAM
- acts as a buffer and holds data thatās copied from RAM, ready for CPU to process it
How does the MDR and the MAR work together?
The MAR knows where to look for data in RAM, and the MDR keeps hold of that data until itās ready to be used by CPU
explain the control unit
it coordinates all the activities taking place
like a comductor of an orchestra
what are the main parts of a processor register (6 of them)?
- accumulator
- MDR
- CIR
- PC
- MAR
- Main Memory
in a processor registerā¦
what does the PC do?
points to the next instruction
in a processor registerā¦
what does CIR stand for?
Current Instruction Register
in a processor registerā¦
What is the CIRās function?
Holds the current instruction to be excecuted
how does the CPU operate (hint: it repeats three operations)?
FETCH - DECODE - EXCECUTE
FETCH - DECODE - EXECUTE
explain the FETCH operation
causes the next instruction and any data involved to be fetched from the main memory
FETCH - DECODE - EXECUTE
explain the DECODE operation
decodes the instruction from FETCH
FETCH - DECODE - EXECUTE
explain the EXECUTE operation
carries out the instruction from DECODE
what are the three most common factors which affect the CPUās performance?
- Clock Speed
- Processor Cores
- Type and size of memory
explain what clock/ processor speed is
cycles per second measured in hertz (How much instructions is carried out in a second)
1 Kilojerz (KHz) = 1000 cycles
eg. 1 Hertz (Hz) = 1 instruction per sec. 1 kilohertz (KHZ) = 1000 cycle
cycles is the same as instructions
How does the amount of processor cores one has affects the performance of the CPU?
Modern CPUs often have multiple processing cores, allowing them to execute multiple tasks simultaneously. More cores generally lead to better multitasking performance and increased throughput. However, sometimes the computerās donāt utilise these extra cores, and ends up being a waste
what is another name for type and size memory?
Cache size/memory
define cache memory
- Itās a small amount of very fast, expensive memory in the CPU
- Can be accessed faster than the RAM
- reduces the time required to access frequently used data and instructions, improving overall system performance
how does the size of cache memory affect the CPUās performance?
A larger cache, particularly the level 1 (L1) and level 2 (L2) caches, can reduce the time spent accessing data from main memory
ie. can make the computer run smoother and faster
what is the role of cache memory?
serves as a buffer between the CPU and main memory (RAM), storing frequently accessed data and instructions for quick access by the CPU