Misc. Linux improvements and bug fixes. (#121)

Co-authored-by: Tom Lally <tomlally@protonmail.com>
This commit is contained in:
Tom Lally 2022-09-01 19:46:20 +01:00 committed by GitHub
parent b8d4cf5b29
commit d3a7b3b5a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 101 additions and 104 deletions

View file

@ -6,20 +6,4 @@ uint32_t GetTickCount()
struct timespec ts;
clock_gettime(CLOCK_MONOTONIC, &ts);
return (1000 * ts.tv_sec + ts.tv_nsec / 1000000);
}
#include <cpuid.h>
void (__cpuid)(int __cpuVal[4], unsigned int __leaf)
{
__cpuid(__cpuVal[0], __cpuVal[1], __cpuVal[2], __cpuVal[3], __leaf);
}
#undef __cpuid
#ifdef __clang__
void __cpuidex(int __cpuid_info[4], int __leaf, int __subleaf)
{
__cpuid_count (__leaf, __subleaf, __cpuid_info[0], __cpuid_info[1],
__cpuid_info[2], __cpuid_info[3]);
}
#endif
}