Graphics card: how an image appears
The processor tells the graphics card: “draw these triangles with these shaders and textures,” and the graphics card turns them into millions of colored pixels — 165 times a second. Each pixel is computed almost independently of its neighbors, so a GPU is built not as a few smart cores but as thousands of simple ones running the same program on different data. The model shows a single triangle on a 32 × 20 pixel screen and four compute units that paint it tile by tile.
The GPU die: SM units, L2, memory controllers
A modern GPU die is 300–600 mm² with tens of billions of transistors. Most of the area is taken up by identical compute units — SMs (streaming multiprocessors; AMD calls them CUs). Mid-range cards have a few dozen of them, flagships 128–170; the model has four. Each SM contains about 128 simple cores for floating-point math, a large register file, shared memory and an L1 cache, texture fetch units, and on newer cards also tensor cores for matrices and ray-tracing units.
The command processor is the dispatcher at the entrance. It reads a command buffer from memory, prepared by the driver, and turns “draw 10,000 triangles with this shader” into thousands of small jobs for the SMs. Next to it are fixed-function units for tasks that would be wasteful to run as programs: triangle setup, the rasterizer, and the ROP units, which write pixels, blend transparency and check depth.
The L2 cache is shared by all SMs; on modern cards it is tens of megabytes. It is needed because video memory, although wide, has high latency — hundreds of nanoseconds — while the same textures and vertices are needed by many units at once. Along the edge of the die are the memory controllers (each serving its own GDDR chip), display controllers, video codecs and the PCIe interface.
Compare this with a CPU. A CPU core is huge: a branch predictor, out-of-order execution, big caches — all so that a single chain of instructions runs as fast as possible. A GPU core is a bare-bones arithmetic unit with none of that. The processor is optimized for the latency of one task, the graphics card for the throughput of millions of identical tasks.
Warp: one instruction for 32 pixels
SM cores do not work individually. A group of 32 threads — a warp (a wavefront on AMD) — executes the same instruction at the same time, each thread on its own data: 32 pixels or 32 vertices. This is called SIMT — single instruction, multiple threads. Fetching and decoding instructions is done once for the whole group rather than per core, which is why so many cores fit on the chip.
The price of this approach is branching. If a shader has an if and half the pixels of a warp take one branch while the other half take the other, the warp executes both branches one after the other, switching off the “foreign” threads each time. That is why shader authors avoid branches that depend heavily on the data.
The GPU’s main trick is hiding memory latency with sheer numbers. Reading a texture from video memory takes hundreds of clock cycles. A CPU relies on caches and prediction in such cases, but a GPU simply keeps dozens of warps in each SM at once, and when one is waiting for memory it switches to another that is ready to run — without losing any time. That is why an SM’s register file is huge, ≈ 256 KB: each warp has its own registers, so nothing has to be saved and reloaded on a switch.
In the model you can see this at the “Pixels” step: the 32 × 20 screen is divided into 8 × 10 tiles, each tile is painted by its own SM, and all four work at the same time. The counter shows that a single core would paint the covered pixels one by one, while 4 units of 32 cores finish in a few steps. A real card has dozens of units, thousands of cores and millions of pixels.
Video memory and the data bus
GDDR video memory sits around the die: 8 chips in the model, 4–16 on real cards. Each is connected to its own controller with 32 data bits, giving a bus 128–512 bits wide — a CPU has just 2 channels of 64 bits. Eight chips of 2–3 GB give 16–24 GB of video memory.
Each GDDR pin runs much faster than on DDR5: GDDR6X does 21–24 Gbit/s, GDDR7 28–32 Gbit/s (DDR5-6000 manages 6 Gbit/s). This uses multi-level signaling: GDDR6X sends 2 bits per symbol using four voltage levels (PAM4), GDDR7 sends 3 bits per two symbols using three levels (PAM3). The result: 256 bits × 28 Gbit/s / 8 ≈ 900 GB/s, and up to 1.8 TB/s on flagships with a 512-bit bus.
Why can’t the same be done for a CPU? GDDR is soldered to the board a centimeter or two from the die; the traces are short and identical, with no connectors. Removable DDR5 modules in slots cannot reach such speeds. The flip side is that the capacity is fixed: you cannot “add memory” to a graphics card.
The data bus in the model is the path between the compute units, video memory and the framebuffer: the pixel shader writes colors along it, and the display controller later reads the finished frame. In a single game frame, hundreds of megabytes to gigabytes travel over this bus: textures, geometry, intermediate buffers, the depth buffer. That is why video memory bandwidth is one of a card’s key specs, and why a large L2 helps so much: every cache hit is an access that never had to go over the bus.
The amount of video memory determines how many textures, models and buffers fit at once. If it runs short, the driver keeps part of the data in system RAM and swaps it in over PCIe — tens of gigabytes per second instead of hundreds. Hence the sudden stutters in games with high texture settings.
The pipeline: vertices → rasterization → pixels
The graphics pipeline is the chain of stages every triangle passes through. The vertex shader is a small program that runs for each vertex: it multiplies the vertex coordinates by the model, camera and projection matrices and gets its position on screen. In the model it rotates the triangle by 0.25 radians and converts the three vertices into pixel coordinates on the 32 × 20 screen.
Next, fixed-function units assemble triangles from the vertices, discard invisible ones (off-screen or facing away from the camera) and divide the coordinates by depth — which is why distant objects look smaller. The rasterizer decides which pixels the triangle covers. The classic method (Pineda, 1988) uses edge functions: for the center of a pixel and each of the three edges, it computes which side of the edge the pixel lies on; if it is inside all three, the pixel is covered. Each pixel is tested independently, so the method parallelizes perfectly.
The pixel (fragment) shader computes the color of each covered pixel. Values from the vertices — color, texture coordinates, normals — are smoothly blended with weights equal to the pixel’s barycentric coordinates: the closer the pixel is to a vertex, the greater that vertex’s contribution. In the model, this is how the red, green and blue vertex colors are mixed. In a game, the shader also reads textures and computes lighting, shadows and reflections — hundreds of instructions per pixel.
The final stage is the ROP units. They check the depth buffer (Z-buffer): if something closer to the camera has already been drawn at this spot, the new pixel is discarded. This way objects correctly hide each other no matter in what order they are drawn. Then the ROPs blend the color with what is already stored (for transparency) and write the result to the framebuffer.
A GPU does not draw “the whole triangle, then the next one” but works in tiles: the screen is divided into regions, and different compute units process their regions in parallel. The model shows exactly this: 8 × 10 tiles are handed out to the SM units and filled simultaneously.
One game frame, step by step
1. The processor updates the game world: physics, character behavior, animation, camera position. 2. The engine decides what is visible and builds a list of draw calls: “this model, this shader, these textures.” Through a graphics API (Vulkan, DirectX 12), the driver translates them into commands for the specific GPU and writes them into a command buffer in memory — often thousands of calls per frame.
3. The GPU’s command processor reads the buffer and launches the work. A frame is usually drawn in several passes: first the geometry of all objects is written into intermediate buffers (depth, normals, material colors), then lighting, shadows and reflections are computed, then post-processing — motion blur, anti-aliasing, neural-network upscaling. 4. The finished frame ends up in the framebuffer, and the program says “show it” (Present).
5. The display controller starts sending out the new frame — immediately or at the start of the monitor’s next refresh, depending on the sync mode. 6. The pixels go out over DisplayPort, and the monitor updates the panel line by line.
The time budget is tight: at 165 Hz a frame gets 6.06 ms, at 60 Hz 16.7 ms. The processor and graphics card work as a pipeline: while the GPU draws frame N, the CPU is already preparing frame N+1. So the speed is set by whichever is slower: if the processor cannot prepare commands in time, the graphics card sits idle, and vice versa.
The level demo is a simplified version of the same path for one triangle: command, vertices, rasterization, pixels, writing to video memory and output to the monitor.
The framebuffer
The framebuffer is an area of video memory holding the finished image: 4 bytes per pixel — red, green, blue (8 bits each, 256 levels) and transparency or a padding byte. A 2560 × 1440 frame is 3.7 million pixels × 4 bytes ≈ 14.7 MB. For HDR, 10 bits per channel or 16-bit floating-point numbers are used — up to 8 bytes per pixel.
There are usually two or three buffers. The next frame is drawn into the back buffer, while the display controller outputs the current one from the front buffer; when the frame is ready, they swap roles. Nothing needs to be copied — it is enough to change the address the controller reads from. This way a half-drawn frame never appears on screen.
If the buffers are swapped right in the middle of output, the top part of the screen shows the old frame and the bottom part the new one, with a visible break at the boundary (tearing). Vertical sync (V-Sync) waits for the end of output before swapping — no tearing, but latency goes up. Variable refresh rate (Adaptive-Sync, FreeSync, G-Sync) solves this from the other side: the monitor starts a new frame when the graphics card has finished it.
Why is the framebuffer in video memory rather than system RAM? It is written by thousands of GPU cores and read by the display controller — both on the graphics card. Keeping it in RAM would mean shipping every frame over PCIe. A CPU’s integrated graphics has no video memory of its own and uses shared system RAM — which is why memory speed matters so much for it.
In the model, the framebuffer is 32 × 20 = 640 pixels, 2,560 bytes. The counter shows how many pixels the triangle wrote and how many bytes that is.
Output to the monitor
The display controller is a separate GPU block that takes no part in drawing. At a constant rate it reads the framebuffer line by line, scales and converts colors if needed, and hands the pixels to the DisplayPort or HDMI transmitter. This work goes on all the time, even when the picture does not change.
The size of the stream: 2560 × 1440 × 165 ≈ 608 million pixels per second; at 24 bits per pixel that is ≈ 14.6 Gbit/s plus blanking intervals. DisplayPort 1.4 carries up to 25.9 Gbit/s of payload over four lanes, DisplayPort 2.1 up to 77 Gbit/s, HDMI 2.1 up to 42 Gbit/s. For 4K at 240 Hz and above, DSC compression is used — visually lossless, by a factor of 2–3.
Before anything is shown, the graphics card and the monitor negotiate. Over an auxiliary channel the card reads the monitor’s EDID — a list of supported resolutions and refresh rates — and then the lanes go through link training to settle on a speed. That is why the image does not appear instantly after you plug in the cable.
The monitor refreshes the screen from top to bottom, line by line, as the data arrives. How the panel works is covered in detail on the “Workstation” level.
Not just graphics: the GPU as a compute engine
Thousands of cores performing the same arithmetic at once are useful wherever there is a lot of data processed in a uniform way: particle physics, photo and video processing, scientific computing. With CUDA, OpenCL or Vulkan compute shaders, a program is written not for pixels but for the elements of any array.
The main use today is neural networks. They are built on multiplying large matrices, and every SM has tensor cores that multiply small matrix blocks in one step at reduced precision — 16, 8 or even 4 bits. A graphics card performs hundreds of trillions of such operations per second, dozens of times more than a CPU.
The same units work in games too: a neural network upscales the image (the frame is rendered at 1440p and reconstructed to 4K) and generates in-between frames. And ray-tracing units search in hardware for which triangle a ray hits — to compute reflections and shadows properly.
The limitations are branching and data transfer. Tasks with little data but lots of logic and conditions (a compiler, a browser, a database) run poorly on a GPU: warps diverge across branches, and transfers over PCIe eat up the gains. That is why the processor and the graphics card complement each other rather than replace one another.
Common misconceptions
“More video memory means a faster graphics card.” Capacity matters only while there is not enough of it. Speed is determined by the number of units, the clock speed and memory bandwidth: a 16 GB card with a narrow bus can turn out slower than a 12 GB card with a wide one.
“A GPU core is the same as a CPU core, just thousands of them.” A graphics card “core” is a single arithmetic lane without its own decoder or scheduler. Conceptually, a whole SM is closer to a CPU core. Comparing CPU and GPU core counts is meaningless.
“FPS above the monitor’s refresh rate is useless.” A 165 Hz monitor will not show 300 frames per second, but the frame it does show will be fresher, and the delay from action to image will be shorter. In competitive games this is noticeable; in others it makes more sense to cap FPS and save power and noise.
“You can plug the monitor into any port.” The ports on the motherboard’s rear panel output the CPU’s integrated graphics. If you connect the monitor there instead of to the graphics card, the game will run on integrated graphics or there will be no image at all.