Large Programs

Home / History of AI

History of AI

Why AI needs GPUs: the chips behind the chatbot

The chip that runs modern AI was invented for video games. A GPU (graphics processing unit) was built to draw millions of pixels at once - and it turns out that drawing pixels and training a chatbot need the same talent: doing huge numbers of simple calculations at the same time.

CPU vs GPU: one expert vs a crowd

A CPU (central processing unit) is the main chip in any computer. It is like a brilliant all-rounder: it handles a few complicated jobs very quickly, one after another - opening apps, browsing the web, running the operating system.

A GPU is different. Instead of a few powerful cores, it has thousands of small, simple ones. Each core is not very clever on its own, but they all work at the same time. That is exactly what graphics needs: every pixel on your screen needs its colour calculated, and none of them need to wait for the others.

What this has to do with AI

Inside a neural network, almost all the work is one kind of maths: multiplying long lists of numbers and adding them up, over and over. A large language model does this with billions of parameters. None of these calculations are hard - but there are trillions of them, and they are mostly independent, so they can run side by side. That makes them perfect for a GPU's crowd of small cores and painfully slow on a CPU's few big ones. Training that would take years on CPUs can finish in weeks on thousands of GPUs working together.

From game shops to data centres

Researchers realised around 2012 that GPUs could supercharge neural networks - the famous AlexNet moment was trained on gaming GPUs - and the deep learning boom followed. Today, companies build enormous data centres packed with AI chips, GPUs have become some of the most wanted hardware on Earth, and their hunger for electricity is a big part of AI's energy story. GPUs are not only for training, either: every answer a chatbot gives you is computed on AI chips too, which is why running a popular chatbot takes whole warehouses of them. You can read more in how LLMs run on computers and training vs inference.

The one-sentence version

AI needs GPUs because a neural network is mostly one simple sum repeated trillions of times - and GPUs are the champions of doing simple sums in parallel.

Source: NVIDIA Blog, "What's the difference between a CPU and a GPU?" (updated explainer), blogs.nvidia.com.