mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2025-06-10 14:58:13 -05:00
Core: Make PerfStats internally locked
More ergonomic to use and will be required for upcoming changes.
This commit is contained in:
@ -110,8 +110,7 @@ void System::PrepareReschedule() {
|
||||
}
|
||||
|
||||
PerfStats::Results System::GetAndResetPerfStats() {
|
||||
auto perf_stats = this->perf_stats.Lock();
|
||||
return perf_stats->GetAndResetStats(CoreTiming::GetGlobalTimeUs());
|
||||
return perf_stats.GetAndResetStats(CoreTiming::GetGlobalTimeUs());
|
||||
}
|
||||
|
||||
void System::Reschedule() {
|
||||
@ -147,7 +146,7 @@ System::ResultStatus System::Init(EmuWindow* emu_window, u32 system_mode) {
|
||||
|
||||
// Reset counters and set time origin to current frame
|
||||
GetAndResetPerfStats();
|
||||
perf_stats.Lock()->BeginSystemFrame();
|
||||
perf_stats.BeginSystemFrame();
|
||||
|
||||
return ResultStatus::Success;
|
||||
}
|
||||
|
Reference in New Issue
Block a user