diff options
author | Keith Davis <keith.davis@arm.com> | 2020-02-03 14:47:54 +0000 |
---|---|---|
committer | Jim Flynn <jim.flynn@arm.com> | 2020-02-03 15:56:49 +0000 |
commit | 9d0ff74843b9d36d9f233d208e18a96de1b7d47b (patch) | |
tree | 15a5b23e39890a8e19b546f927f2b52168eaa7c6 | |
parent | 9789702c0b276ca9518e590f30465da7e76a940f (diff) | |
download | armnn-9d0ff74843b9d36d9f233d208e18a96de1b7d47b.tar.gz |
IVGCVSW-4334 Wire Signed Quantized 8 bit type into ACL
* Add QSymmS8 LayerSupport tests for all backends
* Update BatchNormalization IsLayerSupport Bias' QSymmS8 case
Signed-off-by: Keith Davis <keith.davis@arm.com>
Change-Id: Ib66befe11f9df5956869eb80699fc415a4d3fa16
4 files changed, 21 insertions, 0 deletions
diff --git a/src/backends/backendsCommon/WorkloadFactory.cpp b/src/backends/backendsCommon/WorkloadFactory.cpp index 5671761723..283e748038 100644 --- a/src/backends/backendsCommon/WorkloadFactory.cpp +++ b/src/backends/backendsCommon/WorkloadFactory.cpp @@ -352,6 +352,7 @@ bool IWorkloadFactory::IsLayerSupported(const BackendId& backendId, break; } case DataType::QAsymmU8: + case DataType::QSymmS8: case DataType::QSymmS16: { biasInfoPtr = &dummyQA8Bias; diff --git a/src/backends/cl/test/ClLayerSupportTests.cpp b/src/backends/cl/test/ClLayerSupportTests.cpp index 35e1172161..8d10375778 100644 --- a/src/backends/cl/test/ClLayerSupportTests.cpp +++ b/src/backends/cl/test/ClLayerSupportTests.cpp @@ -43,6 +43,13 @@ BOOST_FIXTURE_TEST_CASE(IsLayerSupportedUint8Cl, ClContextControlFixture) IsLayerSupportedTests<armnn::ClWorkloadFactory, armnn::DataType::QAsymmU8>(&factory); } +BOOST_FIXTURE_TEST_CASE(IsLayerSupportedInt8Cl, ClContextControlFixture) +{ + armnn::ClWorkloadFactory factory = + ClWorkloadFactoryHelper::GetFactory(ClWorkloadFactoryHelper::GetMemoryManager()); + IsLayerSupportedTests<armnn::ClWorkloadFactory, armnn::DataType::QSymmS8>(&factory); +} + BOOST_FIXTURE_TEST_CASE(IsConvertFp16ToFp32SupportedCl, ClContextControlFixture) { std::string reasonIfUnsupported; diff --git a/src/backends/neon/test/NeonLayerSupportTests.cpp b/src/backends/neon/test/NeonLayerSupportTests.cpp index 57e69ec591..e147dc5661 100644 --- a/src/backends/neon/test/NeonLayerSupportTests.cpp +++ b/src/backends/neon/test/NeonLayerSupportTests.cpp @@ -41,6 +41,13 @@ BOOST_AUTO_TEST_CASE(IsLayerSupportedUint8Neon) IsLayerSupportedTests<armnn::NeonWorkloadFactory, armnn::DataType::QAsymmU8>(&factory); } +BOOST_AUTO_TEST_CASE(IsLayerSupportedInt8Neon) +{ + armnn::NeonWorkloadFactory factory = + NeonWorkloadFactoryHelper::GetFactory(NeonWorkloadFactoryHelper::GetMemoryManager()); + IsLayerSupportedTests<armnn::NeonWorkloadFactory, armnn::DataType::QSymmS8>(&factory); +} + BOOST_AUTO_TEST_CASE(IsConvertFp16ToFp32SupportedNeon) { std::string reasonIfUnsupported; diff --git a/src/backends/reference/test/RefLayerSupportTests.cpp b/src/backends/reference/test/RefLayerSupportTests.cpp index ab0809d90b..f0c49aceb0 100644 --- a/src/backends/reference/test/RefLayerSupportTests.cpp +++ b/src/backends/reference/test/RefLayerSupportTests.cpp @@ -66,6 +66,12 @@ BOOST_AUTO_TEST_CASE(IsLayerSupportedUint8Reference) IsLayerSupportedTests<armnn::RefWorkloadFactory, armnn::DataType::QAsymmU8>(&factory); } +BOOST_AUTO_TEST_CASE(IsLayerSupportedInt8Reference) +{ + armnn::RefWorkloadFactory factory; + IsLayerSupportedTests<armnn::RefWorkloadFactory, armnn::DataType::QSymmS8>(&factory); +} + BOOST_AUTO_TEST_CASE(IsLayerSupportedInt16Reference) { armnn::RefWorkloadFactory factory; |