From 7e353082ac79bef59d48602f9196cf804d3dfc4f Mon Sep 17 00:00:00 2001 From: Morph <39850852+Morph1984@users.noreply.github.com> Date: Wed, 1 Mar 2023 20:07:59 -0500 Subject: main: (Windows) Set the current timer resolution to the maximum Increases the precision of thread sleeps on Windows. --- src/yuzu_cmd/yuzu.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/yuzu_cmd') diff --git a/src/yuzu_cmd/yuzu.cpp b/src/yuzu_cmd/yuzu.cpp index 77edd58ca..5f39ece32 100644 --- a/src/yuzu_cmd/yuzu.cpp +++ b/src/yuzu_cmd/yuzu.cpp @@ -42,6 +42,8 @@ #include #include + +#include "common/windows/timer_resolution.h" #endif #undef _UNICODE @@ -314,6 +316,8 @@ int main(int argc, char** argv) { #ifdef _WIN32 LocalFree(argv_w); + + Common::Windows::SetCurrentTimerResolutionToMaximum(); #endif MicroProfileOnThreadCreate("EmuThread"); -- cgit v1.2.3