Use int64_t rather than int64

For cross platform and cross compiler portability we use the
standard integer type for a 64-bit integer. MinGW on Windows doesn't
have the definition for `int64`.
This commit is contained in:
Matt Clarkson 2015-03-27 13:39:11 +00:00
parent 65a5ebd638
commit 05eb1f2545

View File

@ -243,7 +243,7 @@ void InitializeSystemInfo() {
SHGetValueA(HKEY_LOCAL_MACHINE,
"HARDWARE\\DESCRIPTION\\System\\CentralProcessor\\0",
"~MHz", nullptr, &data, &data_size)))
cpuinfo_cycles_per_second = (int64)data * (int64)(1000 * 1000); // was mhz
cpuinfo_cycles_per_second = (int64_t)data * (int64_t)(1000 * 1000); // was mhz
else
cpuinfo_cycles_per_second = EstimateCyclesPerSecond();
// TODO: also figure out cpuinfo_num_cpus