Hardcode frequency on Apple Silicon

On Apple Silicon, PPCTimer estimates a terribily inaccurate RSTSC frequency and results in games (specifically tested Color Splash & MK8) run extremely fast especially in the title screens which unsurpisingly doesn't work that well.
The value hardcoded is the same frequency as on Rosetta.
Admittedly this probably isn't the best solution however it is accurate and it works.
This commit is contained in:
Exverge 2024-07-06 15:18:22 -04:00
parent 6786bcaaf5
commit 72af6e8ae4
No known key found for this signature in database
GPG key ID: 19AAFC0AC6A9B35A

View file

@ -27,6 +27,8 @@ uint64 HighResolutionTimer::m_freq = []() -> uint64 {
LARGE_INTEGER freq;
QueryPerformanceFrequency(&freq);
return (uint64)(freq.QuadPart);
#elif BOOST_OS_MACOS && defined(__arm64__)
return 1000000000;
#else
timespec pc;
clock_getres(CLOCK_MONOTONIC_RAW, &pc);