Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/wolfpld/tracy.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBartosz Taudul <wolf.pld@gmail.com>2019-06-02 16:00:38 +0300
committerBartosz Taudul <wolf.pld@gmail.com>2019-06-02 16:00:38 +0300
commit56810964869ec48e0d91284fb4b15300249b80bd (patch)
treebf3e585104dce057105591b97f4db4bcd66c91f2 /server/TracyWorker.hpp
parent96b1df67b9ffd465a235512cb307e355902bf2bd (diff)
Track status of worker background tasks.
Diffstat (limited to 'server/TracyWorker.hpp')
-rw-r--r--server/TracyWorker.hpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/server/TracyWorker.hpp b/server/TracyWorker.hpp
index 53004f8e..f2267678 100644
--- a/server/TracyWorker.hpp
+++ b/server/TracyWorker.hpp
@@ -323,6 +323,7 @@ public:
bool HasData() const { return m_hasData.load( std::memory_order_acquire ); }
bool IsConnected() const { return m_connected.load( std::memory_order_relaxed ); }
bool IsDataStatic() const { return !m_thread.joinable(); }
+ bool IsBackgroundDone() const { return m_backgroundDone.load( std::memory_order_relaxed ); }
void Shutdown() { m_shutdown.store( true, std::memory_order_relaxed ); }
void Disconnect() { Shutdown(); } // TODO: Needs proper implementation.
@@ -464,6 +465,7 @@ private:
std::atomic<bool> m_hasData;
std::atomic<bool> m_shutdown { false };
+ std::atomic<bool> m_backgroundDone { true };
std::thread m_threadBackground;
int64_t m_delay;