aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/kernel.cpp
diff options
context:
space:
mode:
authorlizzie <lizzie@eden-emu.dev>2025-11-17 22:37:45 +0100
committercrueter <crueter@eden-emu.dev>2025-11-17 22:37:45 +0100
commitd1ac5b2e5041447652284ea523f98d7291190876 (patch)
tree79e4dd84c41150e5924d38af7635620b2a6c75df /src/core/hle/kernel/kernel.cpp
parentc160d6b752e6cfad0353e73a398b246e878a647a (diff)
[qt_common, core, audio] remove duplicate string literal definitions, inline SystemManager::threadfunc, increase latency of audio shutdown (#3030)
Very small code cleanup, also remove `[[unlikely]]` because it doesn't matter + increase latency of audio render when shutting down Signed-off-by: lizzie lizzie@eden-emu.dev Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3030 Reviewed-by: Caio Oliveira <caiooliveirafarias0@gmail.com> Reviewed-by: crueter <crueter@eden-emu.dev> Co-authored-by: lizzie <lizzie@eden-emu.dev> Co-committed-by: lizzie <lizzie@eden-emu.dev>
Diffstat (limited to 'src/core/hle/kernel/kernel.cpp')
-rw-r--r--src/core/hle/kernel/kernel.cpp23
1 files changed, 11 insertions, 12 deletions
diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp
index 1cc060827d..1889ed9938 100644
--- a/src/core/hle/kernel/kernel.cpp
+++ b/src/core/hle/kernel/kernel.cpp
@@ -1056,21 +1056,20 @@ static std::jthread RunHostThreadFunc(KernelCore& kernel, KProcess* process,
// Register the thread.
KThread::Register(kernel, thread);
- return std::jthread(
- [&kernel, thread, thread_name_{std::move(thread_name)}, func_{std::move(func)}] {
- // Set the thread name.
- Common::SetCurrentThreadName(thread_name_.c_str());
+ return std::jthread([&kernel, thread, thread_name_{std::move(thread_name)}, func_{std::move(func)}] {
+ // Set the thread name.
+ Common::SetCurrentThreadName(thread_name_.c_str());
- // Set the thread as current.
- kernel.RegisterHostThread(thread);
+ // Set the thread as current.
+ kernel.RegisterHostThread(thread);
- // Run the callback.
- func_();
+ // Run the callback.
+ func_();
- // Close the thread.
- // This will free the process if it is the last reference.
- thread->Close();
- });
+ // Close the thread.
+ // This will free the process if it is the last reference.
+ thread->Close();
+ });
}
std::jthread KernelCore::RunOnHostCoreProcess(std::string&& process_name,