diff options
author | Liam <byteslice@airmail.cc> | 2023-02-17 05:16:08 +0100 |
---|---|---|
committer | Liam <byteslice@airmail.cc> | 2023-02-17 15:16:05 +0100 |
commit | 1773a1039f7422df4faac08aa366b6a6bbd645e4 (patch) | |
tree | 9560360871f1fcd6c12df2e77452cf37658309d3 /src/core/hle/kernel/kernel.cpp | |
parent | Merge pull request #9802 from Kelebek1/wait_data_cache (diff) | |
download | yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.tar yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.tar.gz yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.tar.bz2 yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.tar.lz yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.tar.xz yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.tar.zst yuzu-1773a1039f7422df4faac08aa366b6a6bbd645e4.zip |
Diffstat (limited to 'src/core/hle/kernel/kernel.cpp')
-rw-r--r-- | src/core/hle/kernel/kernel.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp index b1922659d..3a68a5633 100644 --- a/src/core/hle/kernel/kernel.cpp +++ b/src/core/hle/kernel/kernel.cpp @@ -29,6 +29,7 @@ #include "core/hle/kernel/k_hardware_timer.h" #include "core/hle/kernel/k_memory_layout.h" #include "core/hle/kernel/k_memory_manager.h" +#include "core/hle/kernel/k_object_name.h" #include "core/hle/kernel/k_page_buffer.h" #include "core/hle/kernel/k_process.h" #include "core/hle/kernel/k_resource_limit.h" @@ -84,6 +85,7 @@ struct KernelCore::Impl { InitializeShutdownThreads(); InitializePhysicalCores(); InitializePreemption(kernel); + InitializeGlobalData(kernel); // Initialize the Dynamic Slab Heaps. { @@ -194,6 +196,8 @@ struct KernelCore::Impl { } } + object_name_global_data.reset(); + // Ensure that the object list container is finalized and properly shutdown. global_object_list_container->Finalize(); global_object_list_container.reset(); @@ -363,6 +367,10 @@ struct KernelCore::Impl { } } + void InitializeGlobalData(KernelCore& kernel) { + object_name_global_data = std::make_unique<KObjectNameGlobalData>(kernel); + } + void MakeApplicationProcess(KProcess* process) { application_process = process; } @@ -838,6 +846,8 @@ struct KernelCore::Impl { std::unique_ptr<KAutoObjectWithListContainer> global_object_list_container; + std::unique_ptr<KObjectNameGlobalData> object_name_global_data; + /// Map of named ports managed by the kernel, which can be retrieved using /// the ConnectToPort SVC. std::unordered_map<std::string, ServiceInterfaceFactory> service_interface_factory; @@ -1138,6 +1148,10 @@ void KernelCore::SetCurrentEmuThread(KThread* thread) { impl->SetCurrentEmuThread(thread); } +KObjectNameGlobalData& KernelCore::ObjectNameGlobalData() { + return *impl->object_name_global_data; +} + KMemoryManager& KernelCore::MemoryManager() { return *impl->memory_manager; } |