summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/k_scheduler.cpp
diff options
context:
space:
mode:
authorliamwhite <liamwhite@users.noreply.github.com>2023-02-15 23:42:45 +0100
committerGitHub <noreply@github.com>2023-02-15 23:42:45 +0100
commit6d77de96dae4763ef78fdea1918b582e5e181653 (patch)
tree0c131de68a68c23f62a8a253b3cf69d3bfc91ee7 /src/core/hle/kernel/k_scheduler.cpp
parentMerge pull request #9782 from arades79/fix-consexpr-value-declaration-usage (diff)
parentgeneral: rename CurrentProcess to ApplicationProcess (diff)
downloadyuzu-6d77de96dae4763ef78fdea1918b582e5e181653.tar
yuzu-6d77de96dae4763ef78fdea1918b582e5e181653.tar.gz
yuzu-6d77de96dae4763ef78fdea1918b582e5e181653.tar.bz2
yuzu-6d77de96dae4763ef78fdea1918b582e5e181653.tar.lz
yuzu-6d77de96dae4763ef78fdea1918b582e5e181653.tar.xz
yuzu-6d77de96dae4763ef78fdea1918b582e5e181653.tar.zst
yuzu-6d77de96dae4763ef78fdea1918b582e5e181653.zip
Diffstat (limited to 'src/core/hle/kernel/k_scheduler.cpp')
-rw-r--r--src/core/hle/kernel/k_scheduler.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/core/hle/kernel/k_scheduler.cpp b/src/core/hle/kernel/k_scheduler.cpp
index d6676904b..d6c214237 100644
--- a/src/core/hle/kernel/k_scheduler.cpp
+++ b/src/core/hle/kernel/k_scheduler.cpp
@@ -328,7 +328,7 @@ u64 KScheduler::UpdateHighestPriorityThreadsImpl(KernelCore& kernel) {
}
void KScheduler::SwitchThread(KThread* next_thread) {
- KProcess* const cur_process = kernel.CurrentProcess();
+ KProcess* const cur_process = GetCurrentProcessPointer(kernel);
KThread* const cur_thread = GetCurrentThreadPointer(kernel);
// We never want to schedule a null thread, so use the idle thread if we don't have a next.
@@ -689,11 +689,11 @@ void KScheduler::RotateScheduledQueue(KernelCore& kernel, s32 core_id, s32 prior
void KScheduler::YieldWithoutCoreMigration(KernelCore& kernel) {
// Validate preconditions.
ASSERT(CanSchedule(kernel));
- ASSERT(kernel.CurrentProcess() != nullptr);
+ ASSERT(GetCurrentProcessPointer(kernel) != nullptr);
// Get the current thread and process.
KThread& cur_thread = GetCurrentThread(kernel);
- KProcess& cur_process = *kernel.CurrentProcess();
+ KProcess& cur_process = GetCurrentProcess(kernel);
// If the thread's yield count matches, there's nothing for us to do.
if (cur_thread.GetYieldScheduleCount() == cur_process.GetScheduledCount()) {
@@ -728,11 +728,11 @@ void KScheduler::YieldWithoutCoreMigration(KernelCore& kernel) {
void KScheduler::YieldWithCoreMigration(KernelCore& kernel) {
// Validate preconditions.
ASSERT(CanSchedule(kernel));
- ASSERT(kernel.CurrentProcess() != nullptr);
+ ASSERT(GetCurrentProcessPointer(kernel) != nullptr);
// Get the current thread and process.
KThread& cur_thread = GetCurrentThread(kernel);
- KProcess& cur_process = *kernel.CurrentProcess();
+ KProcess& cur_process = GetCurrentProcess(kernel);
// If the thread's yield count matches, there's nothing for us to do.
if (cur_thread.GetYieldScheduleCount() == cur_process.GetScheduledCount()) {
@@ -816,11 +816,11 @@ void KScheduler::YieldWithCoreMigration(KernelCore& kernel) {
void KScheduler::YieldToAnyThread(KernelCore& kernel) {
// Validate preconditions.
ASSERT(CanSchedule(kernel));
- ASSERT(kernel.CurrentProcess() != nullptr);
+ ASSERT(GetCurrentProcessPointer(kernel) != nullptr);
// Get the current thread and process.
KThread& cur_thread = GetCurrentThread(kernel);
- KProcess& cur_process = *kernel.CurrentProcess();
+ KProcess& cur_process = GetCurrentProcess(kernel);
// If the thread's yield count matches, there's nothing for us to do.
if (cur_thread.GetYieldScheduleCount() == cur_process.GetScheduledCount()) {