summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/thread.h
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2018-10-26 00:42:50 +0200
committerLioncash <mathew1800@gmail.com>2018-10-26 18:49:11 +0200
commit6594853eb112f265fe2354723160c0d4e1cb761a (patch)
tree60e67d4d7f38d8f1fe5bebe01f3ef0d87881c570 /src/core/hle/kernel/thread.h
parentMerge pull request #1533 from FernandoS27/lmem (diff)
downloadyuzu-6594853eb112f265fe2354723160c0d4e1cb761a.tar
yuzu-6594853eb112f265fe2354723160c0d4e1cb761a.tar.gz
yuzu-6594853eb112f265fe2354723160c0d4e1cb761a.tar.bz2
yuzu-6594853eb112f265fe2354723160c0d4e1cb761a.tar.lz
yuzu-6594853eb112f265fe2354723160c0d4e1cb761a.tar.xz
yuzu-6594853eb112f265fe2354723160c0d4e1cb761a.tar.zst
yuzu-6594853eb112f265fe2354723160c0d4e1cb761a.zip
Diffstat (limited to '')
-rw-r--r--src/core/hle/kernel/thread.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/core/hle/kernel/thread.h b/src/core/hle/kernel/thread.h
index f4d7bd235..4a6e11239 100644
--- a/src/core/hle/kernel/thread.h
+++ b/src/core/hle/kernel/thread.h
@@ -258,6 +258,14 @@ public:
return last_running_ticks;
}
+ u64 GetTotalCPUTimeTicks() const {
+ return total_cpu_time_ticks;
+ }
+
+ void UpdateCPUTimeTicks(u64 ticks) {
+ total_cpu_time_ticks += ticks;
+ }
+
s32 GetProcessorID() const {
return processor_id;
}
@@ -378,7 +386,8 @@ private:
u32 nominal_priority = 0; ///< Nominal thread priority, as set by the emulated application
u32 current_priority = 0; ///< Current thread priority, can be temporarily changed
- u64 last_running_ticks = 0; ///< CPU tick when thread was last running
+ u64 total_cpu_time_ticks = 0; ///< Total CPU running ticks.
+ u64 last_running_ticks = 0; ///< CPU tick when thread was last running
s32 processor_id = 0;