Posts Tagged ‘32 bit’

64 bit games on the horizon, but not here yet.

Wednesday, February 11th, 2009

As modern machines are moving more and more towards 64 bit, we are receiving a growing number of requests for 64 bit binaries of our games. This semi-technical article will illustrate how we do plan to create 64 bit binaries in the end, and to give you an overview as to why we haven’t done so before.

The first stumbling block to 64 bit, is the build environment. The build environment is absolutely essential, and it is what allows us to create a game that works on all Linux distros. Over many years, we have tuned our 32 bit system to find a set of libraries and build tools that are cross-distro compatible with pretty much any Linux distro out there. The discussion of this in detail will be for another day, but finding a comparable cross-distro environment for 64 bit is the work of many months of solid research, costing tens of thousands of pounds.

The second problem is the code itself. Only in the last 12 months or so have a few games started to come out for Windows with 64 and 32 bit versions. Most games, even today, are 32 bit only. This means that assumptions have been made about the sizes of pointers, and sizes of various data types, that do not hold true for 64 bit. The biggest issue there is the size of pointers. Various aspects of the game rely on a pointer being 4 bytes in size, and suddenly throwing an 8 byte pointer into the mix is guaranteed to cause problems. This is something that, depending on the way the program is written, is incredibly hard to work around.

Data types such as long int, are easier to work around. Simply replacing all long int variables to be an int32_t will solve that issue with no problem – unless of course the game uses pointer arithmetic. I have never seen a game that does not use pointer arithmetic. This means we cannot make blanket substitutions, every variable in the whole program, sometimes millions of lines, tens of thousands of variables, needs to be examined in depth.

Once we have all of these factors addressed, we will be in a position to produce a 64 bit version of a game. An estimated 3-6 months advance work making a build environment template, probably 25% extra development time increase for the project, and we end up with a speed increase that is not large enough to warrant the extra development time. Our research shows that 64 bit versions of games would run around 5% faster than 32 bit, and you would get more of a performance increase by closing down your web browser when playing, than by running 64 bit.

With the impatience our customers have for new games, we have for now made the call to bring the game to release earlier, than to have a 64 bit version. As and when we license a game that is available as source for 64 and 32 bit, we will certainly spend the time doing the work to build an appropriate build environment, so that we can take advantage of the source, but the costs and risks of doing this to an entire source base that is not designed for it are too high to justify.

  • Share/Bookmark