diff options
| author | 2018-08-05 22:07:28 -0400 | |
|---|---|---|
| committer | 2018-08-05 22:07:30 -0400 | |
| commit | a0c3a46aa9d2186e833bdc1872f9eb877230b429 (patch) | |
| tree | a8715386f729ac3b10f0862de5e8b08537495673 /src/core/core_timing.cpp | |
| parent | Merge pull request #927 from bunnei/fix-texs (diff) | |
| download | yuzu-a0c3a46aa9d2186e833bdc1872f9eb877230b429.tar.gz yuzu-a0c3a46aa9d2186e833bdc1872f9eb877230b429.tar.xz yuzu-a0c3a46aa9d2186e833bdc1872f9eb877230b429.zip | |
core_timing: Make GetGlobalTimeUs() return std::chrono::microseconds
Enforces the time unit being returned and also allows using the standard
time utilities to manipulate it.
Diffstat (limited to 'src/core/core_timing.cpp')
| -rw-r--r-- | src/core/core_timing.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/core_timing.cpp b/src/core/core_timing.cpp index a1b6f96f1..9c934478b 100644 --- a/src/core/core_timing.cpp +++ b/src/core/core_timing.cpp | |||
| @@ -226,8 +226,8 @@ void Idle() { | |||
| 226 | downcount = 0; | 226 | downcount = 0; |
| 227 | } | 227 | } |
| 228 | 228 | ||
| 229 | u64 GetGlobalTimeUs() { | 229 | std::chrono::microseconds GetGlobalTimeUs() { |
| 230 | return GetTicks() * 1000000 / BASE_CLOCK_RATE; | 230 | return std::chrono::microseconds{GetTicks() * 1000000 / BASE_CLOCK_RATE}; |
| 231 | } | 231 | } |
| 232 | 232 | ||
| 233 | int GetDowncount() { | 233 | int GetDowncount() { |