summaryrefslogtreecommitdiff
path: root/src/common/wall_clock.h
diff options
context:
space:
mode:
authorGravatar Morph2022-01-30 12:57:23 -0500
committerGravatar Morph2022-01-30 12:57:23 -0500
commit6267110b694d3b3f8a8561c61ad6b4a4548873b5 (patch)
tree5255d1ef13ff15fd65c4dfa535b366856cbd8c85 /src/common/wall_clock.h
parentcommon: wall_clock: Utilize constants for ms, us, and ns ratios (diff)
downloadyuzu-6267110b694d3b3f8a8561c61ad6b4a4548873b5.tar.gz
yuzu-6267110b694d3b3f8a8561c61ad6b4a4548873b5.tar.xz
yuzu-6267110b694d3b3f8a8561c61ad6b4a4548873b5.zip
common: wall_clock: Check precision against the emulated CPU and CNTFRQ
In addition to requiring nanosecond precision, using the native clock requires that the hardware TSC has a precision greater than the emulated CPU and its clock counter.
Diffstat (limited to 'src/common/wall_clock.h')
-rw-r--r--src/common/wall_clock.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/wall_clock.h b/src/common/wall_clock.h
index 4d132c531..874448c27 100644
--- a/src/common/wall_clock.h
+++ b/src/common/wall_clock.h
@@ -53,7 +53,7 @@ private:
53 bool is_native; 53 bool is_native;
54}; 54};
55 55
56[[nodiscard]] std::unique_ptr<WallClock> CreateBestMatchingClock(u32 emulated_cpu_frequency, 56[[nodiscard]] std::unique_ptr<WallClock> CreateBestMatchingClock(u64 emulated_cpu_frequency,
57 u32 emulated_clock_frequency); 57 u64 emulated_clock_frequency);
58 58
59} // namespace Common 59} // namespace Common