summaryrefslogtreecommitdiff
path: root/src/core/arm/arm_interface.cpp
diff options
context:
space:
mode:
authorGravatar bunnei2022-09-05 18:19:30 -0700
committerGravatar bunnei2022-10-18 19:13:34 -0700
commit57a77e9ff4b4a63c106c0ac3448a8f1452b5384c (patch)
treefda85e063fac9e098ebd7848d8de2ae3ef6b7e45 /src/core/arm/arm_interface.cpp
parentcore: hle: kernel: Add KDynamicResourceManager. (diff)
downloadyuzu-57a77e9ff4b4a63c106c0ac3448a8f1452b5384c.tar.gz
yuzu-57a77e9ff4b4a63c106c0ac3448a8f1452b5384c.tar.xz
yuzu-57a77e9ff4b4a63c106c0ac3448a8f1452b5384c.zip
core: hle: kernel: k_thread: Implement thread termination DPC.
Diffstat (limited to 'src/core/arm/arm_interface.cpp')
-rw-r--r--src/core/arm/arm_interface.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/arm/arm_interface.cpp b/src/core/arm/arm_interface.cpp
index 953d96439..29ba562dc 100644
--- a/src/core/arm/arm_interface.cpp
+++ b/src/core/arm/arm_interface.cpp
@@ -134,6 +134,14 @@ void ARM_Interface::Run() {
134 } 134 }
135 system.ExitDynarmicProfile(); 135 system.ExitDynarmicProfile();
136 136
137 // If the thread is scheduled for termination, exit the thread.
138 if (current_thread->HasDpc()) {
139 if (current_thread->IsTerminationRequested()) {
140 current_thread->Exit();
141 UNREACHABLE();
142 }
143 }
144
137 // Notify the debugger and go to sleep if a breakpoint was hit, 145 // Notify the debugger and go to sleep if a breakpoint was hit,
138 // or if the thread is unable to continue for any reason. 146 // or if the thread is unable to continue for any reason.
139 if (Has(hr, breakpoint) || Has(hr, no_execute)) { 147 if (Has(hr, breakpoint) || Has(hr, no_execute)) {