Fix for other than i386/x86_64 windows archs

Fix for other than i386/x86_64 windows archs.
Timestamp update.
This commit is contained in:
Andy Vandijck 2024-02-19 08:52:37 +01:00
parent 8ee4343716
commit 4401d21199
1 changed files with 14 additions and 2 deletions

View File

@ -16,9 +16,13 @@
//-------------------------------------------------------------------------
#ifdef __FCEU_X86_TSC_ENABLE
#if defined(WIN32)
#include <intrin.h>
#if defined(_M_IX86) || defined(_M_AMD64) || defined(__i386__) || defined(__x86_64__)
#include <intrin.h>__
#pragma intrinsic(__rdtsc)
#else
#include <windows.h>
#endif
#else
#if defined(__x86_64_) || defined(__i386__)
#include <x86intrin.h>
#endif
@ -41,9 +45,17 @@ static uint64_t rdtsc()
return val;
#else
#if defined(_M_IX86) || defined(_M_AMD64) || defined(__i386__) || defined(__x86_64__)
return __rdtsc();
#else
LARGE_INTEGER val;
QueryPerformanceCounter(&val);
return (uint64_t)(val.QuadPart);
#endif
}
#endif
+}
#endif
namespace FCEU