diff options
author | Morph <39850852+Morph1984@users.noreply.github.com> | 2023-03-05 08:42:48 +0100 |
---|---|---|
committer | Morph <39850852+Morph1984@users.noreply.github.com> | 2023-03-08 03:17:46 +0100 |
commit | c27a626b5bc1aa2ae593f44b0a7c10ae3c979291 (patch) | |
tree | 6b56bc52947c36073406870e786f54d452835a2a | |
parent | steady_clock: Introduce a real time clock (diff) | |
download | yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.tar yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.tar.gz yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.tar.bz2 yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.tar.lz yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.tar.xz yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.tar.zst yuzu-c27a626b5bc1aa2ae593f44b0a7c10ae3c979291.zip |
-rw-r--r-- | src/common/x64/native_clock.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/common/x64/native_clock.cpp b/src/common/x64/native_clock.cpp index c11590291..3f90343a5 100644 --- a/src/common/x64/native_clock.cpp +++ b/src/common/x64/native_clock.cpp @@ -53,11 +53,11 @@ u64 EstimateRDTSCFrequency() { FencedRDTSC(); // Get the current time. - const auto start_time = Common::SteadyClock::Now(); + const auto start_time = Common::RealTimeClock::Now(); const u64 tsc_start = FencedRDTSC(); // Wait for 250 milliseconds. std::this_thread::sleep_for(std::chrono::milliseconds{250}); - const auto end_time = Common::SteadyClock::Now(); + const auto end_time = Common::RealTimeClock::Now(); const u64 tsc_end = FencedRDTSC(); // Calculate differences. const u64 timer_diff = static_cast<u64>( @@ -75,13 +75,13 @@ NativeClock::NativeClock(u64 emulated_cpu_frequency_, u64 emulated_clock_frequen // Thread to re-adjust the RDTSC frequency after 30 seconds has elapsed. time_sync_thread = std::jthread{[this](std::stop_token token) { // Get the current time. - const auto start_time = Common::SteadyClock::Now(); + const auto start_time = Common::RealTimeClock::Now(); const u64 tsc_start = FencedRDTSC(); // Wait for 30 seconds. if (!Common::StoppableTimedWait(token, std::chrono::seconds{30})) { return; } - const auto end_time = Common::SteadyClock::Now(); + const auto end_time = Common::RealTimeClock::Now(); const u64 tsc_end = FencedRDTSC(); // Calculate differences. const u64 timer_diff = static_cast<u64>( |