aboutsummaryrefslogtreecommitdiff
path: root/src/core/core_timing.h
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2023-06-21 21:12:46 -0700
committerGitHub <noreply@github.com>2023-06-21 21:12:46 -0700
commite3122c5b468fd59b7eded5a3a7300643d05616bc (patch)
tree3fe4c2c0bea83f3bb8849ef8839b9520873d41c2 /src/core/core_timing.h
parent7eb7d56b1bf96267969a913940ae9e35581ab27a (diff)
parent3e6d81a00899f7f488bfedd849edb64f927b124d (diff)
Merge pull request #10086 from Morph1984/coretiming-ng-1
core_timing: Use CNTPCT as the guest CPU tick
Diffstat (limited to 'src/core/core_timing.h')
-rw-r--r--src/core/core_timing.h14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/core/core_timing.h b/src/core/core_timing.h
index e7c4a949f..10db1de55 100644
--- a/src/core/core_timing.h
+++ b/src/core/core_timing.h
@@ -116,14 +116,11 @@ public:
return downcount;
}
- /// Returns current time in emulated CPU cycles
- u64 GetCPUTicks() const;
-
- /// Returns current time in emulated in Clock cycles
+ /// Returns the current CNTPCT tick value.
u64 GetClockTicks() const;
- /// Returns current time in nanoseconds.
- std::chrono::nanoseconds GetCPUTimeNs() const;
+ /// Returns the current GPU tick value.
+ u64 GetGPUTicks() const;
/// Returns current time in microseconds.
std::chrono::microseconds GetGlobalTimeUs() const;
@@ -142,8 +139,7 @@ private:
void Reset();
- std::unique_ptr<Common::WallClock> cpu_clock;
- std::unique_ptr<Common::WallClock> event_clock;
+ std::unique_ptr<Common::WallClock> clock;
s64 global_timer = 0;
@@ -171,7 +167,7 @@ private:
s64 pause_end_time{};
/// Cycle timing
- u64 ticks{};
+ u64 cpu_ticks{};
s64 downcount{};
};