From 7a0fd0f32a65582071c1618a0c92e4c9727efcfc Mon Sep 17 00:00:00 2001 From: "chss95cs@gmail.com" Date: Wed, 14 Dec 2022 09:56:33 -0800 Subject: [PATCH] Remove MaybeYields when vsync is off --- src/xenia/gpu/pm4_command_processor_implement.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/xenia/gpu/pm4_command_processor_implement.h b/src/xenia/gpu/pm4_command_processor_implement.h index 21b9553d4..89dcdf7ca 100644 --- a/src/xenia/gpu/pm4_command_processor_implement.h +++ b/src/xenia/gpu/pm4_command_processor_implement.h @@ -523,19 +523,18 @@ bool COMMAND_PROCESSOR::ExecutePacketType3_WAIT_REG_MEM( PrepareForWait(); if (!cvars::vsync) { // User wants it fast and dangerous. - xe::threading::MaybeYield(); + // do nothing } else { xe::threading::Sleep(std::chrono::milliseconds(wait / 0x100)); + ReturnFromWait(); } - // xe::threading::SyncMemory(); - ReturnFromWait(); if (!worker_running_) { // Short-circuited exit. return false; } } else { - xe::threading::MaybeYield(); + //xe::threading::MaybeYield(); } } } while (!matched);