From cbb66aa4b7ec93e9a64a1dec5ebc4158056ec061 Mon Sep 17 00:00:00 2001 From: Jim Flynn Date: Wed, 15 May 2019 13:03:54 +0100 Subject: IVGCVSW-2972 Support QSymm16 for Merger Change-Id: If2289b2d1fc20f4524fcf4620f01ea3a36d727d2 Signed-off-by: Jim Flynn --- src/backends/reference/RefLayerSupport.cpp | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) (limited to 'src/backends/reference/RefLayerSupport.cpp') diff --git a/src/backends/reference/RefLayerSupport.cpp b/src/backends/reference/RefLayerSupport.cpp index f79c152139..858bd878ae 100644 --- a/src/backends/reference/RefLayerSupport.cpp +++ b/src/backends/reference/RefLayerSupport.cpp @@ -729,11 +729,27 @@ bool RefLayerSupport::IsMergerSupported(const std::vector inp Optional reasonIfUnsupported) const { ignore_unused(descriptor); - ignore_unused(output); - return IsSupportedForDataTypeRef(reasonIfUnsupported, - inputs[0]->GetDataType(), - &TrueFunc<>, - &TrueFunc<>); + + bool supported = true; + std::array supportedTypes = + { + DataType::Float32, + DataType::QuantisedAsymm8, + DataType::QuantisedSymm16 + }; + + supported &= CheckSupportRule(TypeAnyOf(output, supportedTypes), reasonIfUnsupported, + "Reference concatenation: output type not supported"); + for (const TensorInfo* input : inputs) + { + supported &= CheckSupportRule(TypeAnyOf(*input, supportedTypes), reasonIfUnsupported, + "Reference concatenation: input type not supported"); + + supported &= CheckSupportRule(TypesAreEqual(*input, output), reasonIfUnsupported, + "Reference concatenation: input and output types mismatched."); + } + + return supported; } bool RefLayerSupport::IsMemCopySupported(const TensorInfo &input, -- cgit v1.2.1