הערה
הגישה לדף זה מחייבת הרשאה. באפשרותך לנסות להיכנס או לשנות מדריכי כתובות.
הגישה לדף זה מחייבת הרשאה. באפשרותך לנסות לשנות מדריכי כתובות.
When you use the Microsoft C++ (MSVC) compiler to create applications to run on a 64-bit Windows operating system, you should be aware of the following issues:
An
intand alongare 32-bit values on 64-bit Windows operating systems. For programs that you plan to compile for 64-bit platforms, you should be careful not to assign pointers to 32-bit variables. Pointers are 64-bit on 64-bit platforms, and you will truncate the pointer value if you assign it to a 32-bit variable.size_t,time_t, andptrdiff_tare 64-bit values on 64-bit Windows operating systems.time_tis a 32-bit value on 32-bit Windows operating systems in Visual Studio 2005 and earlier.time_tis now a 64-bit integer by default. For more information, see Time Management.You should be aware of where your code takes an
intvalue and processes it as asize_tortime_tvalue. It is possible that the number could grow to be larger than a 32-bit number and data will be truncated when it is passed back to theintstorage.
The %x (hex int format) printf modifier will not work as expected on a 64-bit Windows operating system. It will only operate on the first 32 bits of the value that is passed to it.
Use %I32x to display a 32-bit integral type in hex format.
Use %I64x to display a 64-bit integral type in hex format.
The %p (hex format for a pointer) will work as expected on a 64-bit Windows operating system.
For more information, see:
See also
Configure C++ projects for 64-bit, x64 targets
Microsoft C++ Porting and Upgrading Guide