summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/process.h
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2021-01-03 10:49:18 +0100
committerbunnei <bunneidev@gmail.com>2021-01-29 06:42:25 +0100
commit4dbf3f4880cac69db21cc8f18582814dc986c854 (patch)
tree16bd5c45c3341e3341d3581e830dbc9f5067784d /src/core/hle/kernel/process.h
parenthle: kernel: KThread: Reorganize thread priority defaults. (diff)
downloadyuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.tar
yuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.tar.gz
yuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.tar.bz2
yuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.tar.lz
yuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.tar.xz
yuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.tar.zst
yuzu-4dbf3f4880cac69db21cc8f18582814dc986c854.zip
Diffstat (limited to '')
-rw-r--r--src/core/hle/kernel/process.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/hle/kernel/process.h b/src/core/hle/kernel/process.h
index db01d6c8a..5a2cfdb36 100644
--- a/src/core/hle/kernel/process.h
+++ b/src/core/hle/kernel/process.h
@@ -173,10 +173,15 @@ public:
std::shared_ptr<ResourceLimit> GetResourceLimit() const;
/// Gets the ideal CPU core ID for this process
- u8 GetIdealCore() const {
+ u8 GetIdealCoreId() const {
return ideal_core;
}
+ /// Checks if the specified thread priority is valid.
+ bool CheckThreadPriority(s32 prio) const {
+ return ((1ULL << prio) & GetPriorityMask()) != 0;
+ }
+
/// Gets the bitmask of allowed cores that this process' threads can run on.
u64 GetCoreMask() const {
return capabilities.GetCoreMask();