diff options
author | Lioncash <mathew1800@gmail.com> | 2018-09-21 07:26:29 +0200 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2018-09-21 09:50:12 +0200 |
commit | acfc801d14b1883f54b8fe66ac428982f9898258 (patch) | |
tree | efb94a0647b8756638fc4d95d18ad9782578ce4c /src/core/hle/kernel/thread.h | |
parent | Added support for uncompressed NSOs (#1374) (diff) | |
download | yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.tar yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.tar.gz yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.tar.bz2 yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.tar.lz yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.tar.xz yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.tar.zst yuzu-acfc801d14b1883f54b8fe66ac428982f9898258.zip |
Diffstat (limited to 'src/core/hle/kernel/thread.h')
-rw-r--r-- | src/core/hle/kernel/thread.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/core/hle/kernel/thread.h b/src/core/hle/kernel/thread.h index 91e9b79ec..4250144c3 100644 --- a/src/core/hle/kernel/thread.h +++ b/src/core/hle/kernel/thread.h @@ -62,6 +62,9 @@ enum class ThreadWakeupReason { class Thread final : public WaitObject { public: + using TLSMemory = std::vector<u8>; + using TLSMemoryPtr = std::shared_ptr<TLSMemory>; + /** * Creates and returns a new thread. The new thread is immediately scheduled * @param kernel The kernel instance this thread will be created under. @@ -134,6 +137,14 @@ public: return thread_id; } + TLSMemoryPtr& GetTLSMemory() { + return tls_memory; + } + + const TLSMemoryPtr& GetTLSMemory() const { + return tls_memory; + } + /** * Resumes a thread from waiting */ @@ -269,7 +280,7 @@ private: explicit Thread(KernelCore& kernel); ~Thread() override; - std::shared_ptr<std::vector<u8>> tls_memory = std::make_shared<std::vector<u8>>(); + TLSMemoryPtr tls_memory = std::make_shared<TLSMemory>(); }; /** |