aboutsummaryrefslogtreecommitdiff
path: root/src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp
diff options
context:
space:
mode:
authorJim Flynn <jim.flynn@arm.com>2020-10-08 11:42:30 +0100
committerJim Flynn <jim.flynn@arm.com>2020-10-08 14:24:58 +0000
commit3a40ea5e1efd61ebb21a174ef7bf9adecac8ade9 (patch)
tree2bc713946514f7c3d551641a66bee30dd2a4a7c8 /src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp
parente7ba17ec386ac5e6ddca02f49e9b8e06faa95d4e (diff)
downloadarmnn-3a40ea5e1efd61ebb21a174ef7bf9adecac8ade9.tar.gz
IVGCVSW-5363 Add Unmap layer and Unmap workload
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Signed-off-by: Jim Flynn <jim.flynn@arm.com> Change-Id: Ie5ecfa67e4763d0c058905592fe2e2fd7315f85c
Diffstat (limited to 'src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp')
-rw-r--r--src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp27
1 files changed, 26 insertions, 1 deletions
diff --git a/src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp b/src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp
index 1078c2a8d7..a8465b45f6 100644
--- a/src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp
+++ b/src/backends/backendsCommon/test/IsLayerSupportedTestImpl.hpp
@@ -7,6 +7,7 @@
#include <Graph.hpp>
#include <backendsCommon/MapWorkload.hpp>
+#include <backendsCommon/UnmapWorkload.hpp>
#include <backendsCommon/WorkloadFactory.hpp>
#include <armnn/utility/IgnoreUnused.hpp>
@@ -214,6 +215,22 @@ struct DummyLayer<armnn::SplitterLayer>
armnn::SplitterLayer* m_Layer;
};
+template<>
+struct DummyLayer<armnn::UnmapLayer, void>
+{
+ DummyLayer()
+ {
+ m_Layer = dummyGraph.AddLayer<armnn::UnmapLayer>("");
+ }
+
+ ~DummyLayer()
+ {
+ dummyGraph.EraseLayer(m_Layer);
+ }
+
+ armnn::UnmapLayer* m_Layer;
+};
+
template <typename ConvolutionLayerType>
struct DummyConvolutionLayer
{
@@ -628,7 +645,6 @@ DECLARE_LAYER_POLICY_2_PARAM(Pooling2d)
DECLARE_LAYER_POLICY_2_PARAM(PreCompiled)
DECLARE_LAYER_POLICY_1_PARAM(Prelu)
-
DECLARE_LAYER_POLICY_2_PARAM(QLstm)
DECLARE_LAYER_POLICY_1_PARAM(QuantizedLstm)
@@ -665,6 +681,8 @@ DECLARE_LAYER_POLICY_2_PARAM(Transpose)
DECLARE_LAYER_POLICY_2_PARAM(TransposeConvolution2d)
+DECLARE_LAYER_POLICY_MAP_PARAM(Unmap, void)
+
// Generic implementation to get the number of input slots for a given layer type;
template<armnn::LayerType Type>
@@ -798,6 +816,13 @@ bool IsLayerSupportedTest(FactoryType *factory, Tag<armnn::LayerType::Map>)
return true;
}
+template<typename FactoryType, armnn::DataType DataType, armnn::LayerType Type>
+bool IsLayerSupportedTest(FactoryType *factory, Tag<armnn::LayerType::Unmap>)
+{
+ IgnoreUnused(factory);
+ return true;
+}
+
// Helper function to compute the next type in the LayerType enum.
constexpr armnn::LayerType NextType(armnn::LayerType type)
{