From d95e906f135ab9c7a7ac4c9f5d2cef8beb154a88 Mon Sep 17 00:00:00 2001 From: Matteo Martincigh Date: Thu, 31 Jan 2019 15:35:59 +0000 Subject: IVGCVSW-2603 The macros ARMCOMPUTECL_ENABLED and ARMCOMPUTENEON_ENABLED no longer work * Added two master variables ARMNN_COMPUTE_CL_ENABLED and ARMNN_COMPUTE_NEON_ENABLED to android-nn-driver/Android.mk to easily control backend support * Setting either of those two new variables then properly sets the corresponding build macro * If a specific backend gets disabled, the corresponding source files will be excluded from the build * Unified the usage of the pre-compile macros !android-nn-driver:613 Change-Id: I582ff73493b70ba9e22ca2e38d875a0f19566c8a Signed-off-by: Matteo Martincigh --- src/backends/backendsCommon/test/OptimizedNetworkTests.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/backends/backendsCommon/test/OptimizedNetworkTests.cpp') diff --git a/src/backends/backendsCommon/test/OptimizedNetworkTests.cpp b/src/backends/backendsCommon/test/OptimizedNetworkTests.cpp index 8d88241000..7b6135df71 100644 --- a/src/backends/backendsCommon/test/OptimizedNetworkTests.cpp +++ b/src/backends/backendsCommon/test/OptimizedNetworkTests.cpp @@ -120,7 +120,7 @@ BOOST_AUTO_TEST_CASE(OptimizeValidateDeviceNonSupportLayerWithFallback) // If NEON is enabled, Input and Output layers are supported by CpuAcc, // the other layers are supported by CpuRef. // If NEON is not enabled, all layers are supported by CpuRef. -#if ARMCOMPUTENEON_ENABLED +#if defined(ARMCOMPUTENEON_ENABLED) if (layer->GetType() == armnn::LayerType::Input || layer->GetType() == armnn::LayerType::Output) { BOOST_CHECK(layer->GetBackendId() == armnn::Compute::CpuAcc); @@ -303,7 +303,7 @@ BOOST_AUTO_TEST_CASE(OptimizeValidateWorkloadsDuplicateComputeDeviceWithFallback // If only CL is enabled, Input and Output layers are supported by GpuAcc, // the other layers are supported by CpuRef. // If neither NEON, nor CL is enabled, all layers are supported by CpuRef. -#if ARMCOMPUTENEON_ENABLED +#if defined(ARMCOMPUTENEON_ENABLED) if (layer->GetType() == armnn::LayerType::Input || layer->GetType() == armnn::LayerType::Output) { BOOST_CHECK(layer->GetBackendId() == armnn::Compute::CpuAcc); @@ -312,7 +312,7 @@ BOOST_AUTO_TEST_CASE(OptimizeValidateWorkloadsDuplicateComputeDeviceWithFallback { BOOST_CHECK(layer->GetBackendId() == armnn::Compute::CpuRef); } -#elif ARMCOMPUTECL_ENABLED +#elif defined(ARMCOMPUTECL_ENABLED) if (layer->GetType() == armnn::LayerType::Input || layer->GetType() == armnn::LayerType::Output) { BOOST_CHECK(layer->GetBackendId() == armnn::Compute::GpuAcc); -- cgit v1.2.1