Delaney King

Delaney King



Question about what "CPU bound" means in games in easy layman's terms. Okay so your computer chip (CPU) and your graphics card (GPU) are constantly talking.

The CPU tells the GPU what to draw, and then hands it the mesh, textures and shaders to do it. GPUs are great at parallel processing, which means doing lots of simple things simultaneously. Picture a room full of monkeys with calculators.

If your GPU gets all the instructions on what to draw, and gets all the mesh and texture data on time, it can churn through the work easily. Big room. Lots of monkeys. The problem comes when there are too many instructions for the number of monkeys you have, or the...

Stuff they need to render the scene doesn't get handed to them in time. So no matter how chad your GPU is, if you can't feed it in time, it is basically waiting around doing nothing.

CPU bound means the stress is being put onto your CPU chip side of things, not your GPU. A classic example is draw calls. If you say "draw the teapot" one of your GPU processors can do that without breaking a sweat. If you say "draw six thousand teapots"...

Your GPU does this in parallel, so each little core (monkey) grabs a teapot each, and again, and again and again and... the whole GPU is busy. However, one monkey... er... core is actually capable of handling, say, a thousand teapots each in one go. So really only...

So really you only need six monkeys to draw all the teapots. The way this is done is rather than saying "draw this one single teapot", you weld them all together into one mesh and say "draw this one pile of teapots". We call this "batching" which reduces draw calls.

The CPU is responsible for "state changes". This means handing a new mesh, textures and shader to the GPU. Each separate mesh, each different material, each non instanced shader... that is a state change. If you are constantly switching state, your CPU is busy as fuck.

This is why we atlas textures together, try to keep textures small and share materials as much as we can. It means we can batch, lower the draw calls and state changes, and let the graphics card work at full potential.

Its actually a little more complex than this, but you asked for layman's terms and so I gave you monkeys. This should help you get a handle on why your game engine gives you information on draw calls and shows you performance bars for CPU and GPU.

A lot of graphics cards have chonky memory now, so they cache shaders and textures to reduce the state change time. Be aware that batching everything together too much can also chug, as objects stay in the view frustrum and are not "occlusion culled" (discarded when not visible)

The trick is to watch your engine profiler tools to see where you are getting the chugging happening, and adjusting accordingly. Hope that helps. Again, very simplified explanation, don't give me shit.

If this lesson helped, shout me the price of a coffee here: My patreon will start having game tutorial content starting monday, and all that will be compiled into my book on game art "Violent Triangles". Stay tuned.

Inside your 3d card.

Your CPU deciding on what it need to draw and then collecting all the textures and meshes and shit from memory and your hard drive and sending it to the GPU. Oh and actually running the game code too.

Follow us on Twitter

to be informed of the latest developments and updates!

You can easily use to @tivitikothread bot for create more readable thread!
Donate 💲

You can keep this app free of charge by supporting 😊

for server charges...