Considerations for porting existing C++ applications to 64-bit

Handling variables of type long and pointer

When porting your applications to the Linux 64-bit architecture, you must take special care when handling variables of type long and pointer, since the size of these variables may be platform dependent.

Windows

On Windows, 64-bit applications are supported natively within Visual Studio 2005 and later versions.

  • Refer to the Symphony C++ samples project settings in Visual Studio to see how to port your C++ application to 64-bit on Windows.

  • When compiling the samples for 64-bit using Visual Studio, use the solution files suffixed with "_vc80.sln" or _vc90.sln, depending on your version of Visual Studio. You must also select the "x64" configuration since by default the "Win32" configuration is selected by Visual Studio on first use.

  • Note that only a "full" or "custom" installation of Visual Studio 2005 or Visual Studio 2008 allows you to build 64-bit applications. A "typical" installation only installs the 32-bit components for building.

If you are not using Visual Studio 2005 or a later version, the porting process involves installation and some configuration of the Microsoft Platform Software Development Kit. You can get details on this porting process from Microsoft's MSDN knowledge base.

Linux

On 64-bit versions of Linux, the GCC compiler defaults to compiling for the 64-bit architecture.