tags:

views:

103

answers:

2

What are the guidelines for porting a 32-bit program to a 64-bit version?

+3  A: 

Apart from the obvious issues with calling 32-bit libraries:

  • Don't assume a pointer is the same size as an integer.
  • Don't assume subtracting one pointer from another yields a value that fits in an integer.

See also http://msdn.microsoft.com/en-us/library/aa384190%28VS.85%29.aspx

moonshadow
Thanks for the link.
Ankur
A: 

Don't use hard coded registry/file system paths as some are different on a 64-Bit machine. For example, 32 bit apps get installed in 'Program Files (x86)'.

If you are developing in Windows using .NET, make sure you are using the System or Microsoft.Win32 libraries to access resources.

Philip Wallace