c++ – In game development, what aspects to consider when choosing a 32-bit architecture over a 64-bit architecture?

The most obvious thing to consider is that using a 32-bit architecture for your executable allows you to address about ~4gb of RAM on Windows while using a 64-bit architecture allows the program to address 128gb+. This means that you can put much more stuff into RAM before experiencing issues.

A situation where this could ¤ be an issue is loading your 3d models and their textures into Video RAM. For instance, the machine’s graphics card allows to load 8gb of data (the nVidia DLL will manage this just fine even using a 32-bit app), and you want to take advantage of it, so you’ll create nice models with big, highly detailed textures, which will end up taking 6gb of memory.

With a 64-bit architecture, you would simply have to load everything into RAM, then have the graphics API load it into Video RAM. But with a 32-bit architecture, you’ll need to cut down your loading process into smaller pieces: load a chunk of data into RAM, send it to VRAM, unload it from RAM, then repeat with the other chunks, until everything is done.

¤ Note that this will often depend on how you do things, what you need in your game, and how you’ve arranged your architecture; I used a framework where this was an issue: we loaded an image from disk into RAM, but there was no check telling us that memory couldn’t be assigned, so the rest of the code tried to upload a “null” image into VRAM. We either had strange bugs, at strange places, or some parts of the models just appeared black.