Guidelines to remember while porting C/C++ Applications to 64-bit mode
• Data Truncation
• Avoid assigning longs to ints
• Avoid Storing Pointers in ints
• Avoid Truncating Function Return Values
• Use Appropriate Print Specifiers
• Data Type Promotion
• Avoid Arithmetic between Signed and Unsigned Numbers
• Pointers
• Avoid Pointer Arithmetic between longs and ints
• Avoid Casting Pointers to ints or ints to Pointers
• Avoid Storing Pointers in ints
• Avoid Truncating Function Return Values
• Structures
• Avoid Using Unnamed and Unqualified Bit Fields
• Avoid Passing Invalid Structure References
• Hardcoded Constants
• Avoid Using Literals and Masks that Assume 32 bits
• Avoid Hardcoding Size of Data Types
• Avoid Hardcoding Bit Shift Values
• Avoid Hardcoding Constants with malloc(), memory(3), string(3)
Ref:
Migrating to 64-Bit Environments - http://www.informit.com/guides/printerfriendly.asp?g=cplusplus&seqNum=201
Search this Blog:
C/C++ : Guidelines - Porting to 64bit Operating Systems
Target 32- and 64-bit Platforms Together with a Few Simple Datatype Changes -http://www.devx.com/cplus/Article/27510/1954?pf=true