As computers have become more powerful, not all processing is handled by the CPU alone. In IB Computer Science (HL), students are expected to understand the difference between a Central Processing Unit (CPU) and a Graphics Processing Unit (GPU), and why modern systems use both.
This topic is especially important for understanding performance, parallel processing, and real-world applications such as machine learning and graphics rendering.
What Is a CPU?
The CPU is the main processor in a computer.
It is designed to:
- Execute a wide range of instructions
- Handle complex decision-making
- Manage control flow and program logic
Key characteristics of CPUs:
- Few cores (compared to GPUs)
- Very high clock speeds
- Optimised for sequential processing
- Strong control and branching capabilities
CPUs are general-purpose processors designed to handle many different types of tasks efficiently.
What Is a GPU?
The GPU was originally designed to process graphics, but it is now used for many other tasks.
It is designed to:
- Perform the same operation on large amounts of data
- Handle highly parallel workloads
- Process data simultaneously
Key characteristics of GPUs:
- Hundreds or thousands of smaller cores
- Lower clock speeds per core
- Optimised for parallel processing
- Limited control logic compared to CPUs
GPUs excel at tasks where the same instruction is applied repeatedly to different data values.
Key Architectural Differences
The main difference between CPUs and GPUs lies in how they are built.
- CPUs prioritise:
- Control logic
- Branching
- Low-latency execution
- GPUs prioritise:
- Arithmetic units
- Throughput
- Massive parallelism
A CPU might have 8 powerful cores, while a GPU might have thousands of simpler cores.
When CPUs Are Better Than GPUs
CPUs are better for:
- Running operating systems
- Handling user input
- Managing program flow
- Executing conditional logic
- Tasks that require frequent branching
These tasks benefit from strong control and flexibility.
When GPUs Are Better Than CPUs
GPUs are better for:
- Graphics rendering
- Image and video processing
- Scientific simulations
- Machine learning
- Data-parallel computations
In these cases, GPUs can process large datasets much faster than CPUs.
CPUs, GPUs, and IB Exam Questions
In IB Computer Science HL, students may be asked to:
- Compare CPUs and GPUs
- Explain why GPUs are used in AI or graphics
- Link GPU architecture to performance
- Discuss advantages and limitations
Clear comparisons using architecture and purpose are rewarded.
Common Student Mistakes
Students often:
- Say GPUs are simply “faster CPUs”
- Ignore parallelism
- Forget CPU control roles
- Confuse clock speed with overall performance
Performance depends on task type, not just speed.
Final Thoughts
CPUs and GPUs are designed for different kinds of processing. CPUs handle complex, sequential tasks, while GPUs excel at parallel workloads involving large datasets. Modern computers use both to maximise performance.
Understanding this distinction helps IB HL students explain real-world computing systems accurately — and score higher in performance-related questions.
