aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorKeith Davis <keith.davis@arm.com>2021-08-09 16:49:18 +0100
committerMatthew Sloyan <matthew.sloyan@arm.com>2021-08-10 14:07:27 +0000
commitf487486c843a38fced90229923433d09f99fc2e5 (patch)
tree63a2268196279a5c97c3b9dea86024f0bf4a751e /include
parentbcd860a30eba22bb2ba0943ad705734ce0ec5b23 (diff)
downloadarmnn-f487486c843a38fced90229923433d09f99fc2e5.tar.gz
IVGCVSW-6292 Allow profiling details to be switched off during profiling
* Add switch for network details during profiling Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: I8bd49fd58f0e0255598106e9ab36806ee78391d6
Diffstat (limited to 'include')
-rw-r--r--include/armnn/IProfiler.hpp4
-rw-r--r--include/armnn/IRuntime.hpp32
2 files changed, 23 insertions, 13 deletions
diff --git a/include/armnn/IProfiler.hpp b/include/armnn/IProfiler.hpp
index 5ce42017d9..5fbb67000a 100644
--- a/include/armnn/IProfiler.hpp
+++ b/include/armnn/IProfiler.hpp
@@ -39,6 +39,10 @@ public:
/// @param [out] outStream The stream where to write the profiling results to.
void Print(std::ostream& outStream) const;
+ /// Print out details of each layer within the network that possesses a descriptor.
+ /// Also outputs tensor info.
+ void EnableNetworkDetailsToStdOut();
+
~IProfiler();
IProfiler();
diff --git a/include/armnn/IRuntime.hpp b/include/armnn/IRuntime.hpp
index 1bae94374e..8c269dee49 100644
--- a/include/armnn/IRuntime.hpp
+++ b/include/armnn/IRuntime.hpp
@@ -39,36 +39,40 @@ struct INetworkProperties
m_ExportEnabled(exportEnabled),
m_AsyncEnabled(asyncEnabled),
m_ProfilingEnabled(profilingEnabled),
+ m_OutputNetworkDetails(false),
m_InputSource(m_ImportEnabled ? MemorySource::Malloc : MemorySource::Undefined),
m_OutputSource(m_ExportEnabled ? MemorySource::Malloc : MemorySource::Undefined)
{}
ARMNN_DEPRECATED_MSG("Please use INetworkProperties constructor without numThreads argument")
INetworkProperties(bool asyncEnabled,
- MemorySource m_InputSource,
- MemorySource m_OutputSource,
+ MemorySource inputSource,
+ MemorySource outputSource,
size_t numThreads,
bool profilingEnabled = false)
- : m_ImportEnabled(m_InputSource != MemorySource::Undefined),
- m_ExportEnabled(m_OutputSource != MemorySource::Undefined),
+ : m_ImportEnabled(inputSource != MemorySource::Undefined),
+ m_ExportEnabled(outputSource != MemorySource::Undefined),
m_AsyncEnabled(asyncEnabled),
m_ProfilingEnabled(profilingEnabled),
- m_InputSource(m_InputSource),
- m_OutputSource(m_OutputSource)
+ m_OutputNetworkDetails(false),
+ m_InputSource(inputSource),
+ m_OutputSource(outputSource)
{
armnn::IgnoreUnused(numThreads);
}
INetworkProperties(bool asyncEnabled,
- MemorySource m_InputSource,
- MemorySource m_OutputSource,
- bool profilingEnabled = false)
- : m_ImportEnabled(m_InputSource != MemorySource::Undefined),
- m_ExportEnabled(m_OutputSource != MemorySource::Undefined),
+ MemorySource inputSource,
+ MemorySource outputSource,
+ bool profilingEnabled = false,
+ bool outputDetails = false)
+ : m_ImportEnabled(inputSource != MemorySource::Undefined),
+ m_ExportEnabled(outputSource != MemorySource::Undefined),
m_AsyncEnabled(asyncEnabled),
m_ProfilingEnabled(profilingEnabled),
- m_InputSource(m_InputSource),
- m_OutputSource(m_OutputSource)
+ m_OutputNetworkDetails(outputDetails),
+ m_InputSource(inputSource),
+ m_OutputSource(outputSource)
{}
/// Deprecated and will be removed in future release.
@@ -80,6 +84,8 @@ struct INetworkProperties
const bool m_ProfilingEnabled;
+ const bool m_OutputNetworkDetails;
+
const MemorySource m_InputSource;
const MemorySource m_OutputSource;