In my short time programming, it has been trivial to compile any of my C++, Java, etc. for either a 32 or 64 bit machine so long as I have the full source for the program.But a lot of software is not released 64bit.Most annoyingly, there isn't yet a 64bit release of the Unity engine.What makes it difficult to compile some programs for 64 bit machines?
Why might it be difficult to make a 64 bit version of a program?
compiler;64 bit;32 bit
The general problem is that its very easy to encode undocumented assumptions in a program, and very hard to find places where those assumptions were made. High-level languages tend to insulate us from these concerns somewhat, but in lower-level languages used for implementing platforms and services, its easy to do things that are not necessarily portable across architectures:Assuming that int is large enough to store a pointerAssuming properties of the representation of pointers, e.g., for pointer taggingAssuming that data pointers and code pointers have the same sizeThere is also the practical concern of release management. If I only make an x86 build, it will still run on x86-64, albeit perhaps more slowly due to the limited availability of registers. Whereas if I build for both x86 and x86-64, I must now test on both architectures and deal with bugs that may only arise on one architecture, increasing the cost of shipping a new release.