aboutsummaryrefslogtreecommitdiff
path: root/src/profiling/CommandThread.hpp
diff options
context:
space:
mode:
authorMatteo Martincigh <matteo.martincigh@arm.com>2019-10-04 17:01:07 +0100
committerMatteo Martincigh <matteo.martincigh@arm.com>2019-10-07 10:08:44 +0000
commit8a837179ad883e9b5dd982a25cc5e94f245f79ed (patch)
tree08c798ca632850e0f339ab6b9d50adedd0701c75 /src/profiling/CommandThread.hpp
parent88813936232bc47fc7768800c6895191585570e8 (diff)
downloadarmnn-8a837179ad883e9b5dd982a25cc5e94f245f79ed.tar.gz
IVGCVSW-3937 Rename CommandThread to CommandHandler
* Renamed files, class name and methods accordingly * Updated unit tests accordingly Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com> Change-Id: Ifb88aa61edb93b852a07b1bd59bd259213677b44
Diffstat (limited to 'src/profiling/CommandThread.hpp')
-rw-r--r--src/profiling/CommandThread.hpp65
1 files changed, 0 insertions, 65 deletions
diff --git a/src/profiling/CommandThread.hpp b/src/profiling/CommandThread.hpp
deleted file mode 100644
index 0456ba4372..0000000000
--- a/src/profiling/CommandThread.hpp
+++ /dev/null
@@ -1,65 +0,0 @@
-//
-// Copyright © 2019 Arm Ltd. All rights reserved.
-// SPDX-License-Identifier: MIT
-//
-
-#pragma once
-
-#include "CommandHandlerRegistry.hpp"
-#include "IProfilingConnection.hpp"
-#include "PacketVersionResolver.hpp"
-#include "ProfilingService.hpp"
-
-#include <atomic>
-#include <thread>
-
-namespace armnn
-{
-
-namespace profiling
-{
-
-class CommandThread
-{
-public:
- CommandThread(uint32_t timeout,
- bool stopAfterTimeout,
- CommandHandlerRegistry& commandHandlerRegistry,
- PacketVersionResolver& packetVersionResolver,
- IProfilingConnection& socketProfilingConnection)
- : m_Timeout(timeout)
- , m_StopAfterTimeout(stopAfterTimeout)
- , m_IsRunning(false)
- , m_KeepRunning(false)
- , m_CommandThread()
- , m_CommandHandlerRegistry(commandHandlerRegistry)
- , m_PacketVersionResolver(packetVersionResolver)
- , m_SocketProfilingConnection(socketProfilingConnection)
- {}
- ~CommandThread() { Stop(); }
-
- void Start();
- void Stop();
-
- bool IsRunning() const;
-
- void SetTimeout(uint32_t timeout);
- void SetStopAfterTimeout(bool stopAfterTimeout);
-
-private:
- void WaitForPacket();
-
- std::atomic<uint32_t> m_Timeout;
- std::atomic<bool> m_StopAfterTimeout;
- std::atomic<bool> m_IsRunning;
- std::atomic<bool> m_KeepRunning;
- std::thread m_CommandThread;
-
- CommandHandlerRegistry& m_CommandHandlerRegistry;
- PacketVersionResolver& m_PacketVersionResolver;
- IProfilingConnection& m_SocketProfilingConnection;
-};
-
-} // namespace profiling
-
-} // namespace armnn