Click to See Complete Forum and Search --> : long long int and ULARGE_INTEGER


blakkcooper
November 12th, 2009, 06:37 PM
What is the difference between unsigned long long int and ULARGE_INTEGER? And is ULARGE_INTEGER the same as __int64?

olivthill2
November 13th, 2009, 04:40 AM
unsigned long long int, ULARGE_INTEGER, and unsigned __int64 are integers stored in 64 bits.
FYI, there are also UINT64, ULONGLONG and LONG64, which are also integers stored in 64 bits.

ULARGE_INTEGER is a structure:typedef union _ULARGE_INTEGER {
struct {
DWORD LowPart;
DWORD HighPart;
} ;
struct {
DWORD LowPart;
DWORD HighPart;
} u;
ULONGLONG QuadPart;
}ULARGE_INTEGER, *PULARGE_INTEGER;
(source: http://msdn.microsoft.com/en-us/library/aa383742(VS.85).aspx)

long long is at the source of several other types:#define __int64 long long
typedef __int64 LONG64, *PLONG64;
typedef __int64 INT64, *PINT64;
typedef unsigned __int64 UINT64, *PUINT64;
(source: basestd.h)
Myself, when I program for Windows, I like to use UINT64 and INT64.