IVGCVSW-4473 Android R pre Hal 1_3 build changes
* Update ErrorStatus to V1_0::ErrorStatus
* Update Request to V1_0::Request
* Update OperandType to V1_2::OperandType
* Add namespace android::nn::hal in ArmnnDriverImpl for R only
* Add missing g_RelaxedFloat32toFloat16PerformancePowerUsageName
* Add namespace V1_0 or V1_1 where necessary
* Update Android.mk with R macro and android.hardware.neuralnetworks@1.3
* Remove androidnn.go
* include IAllocator in DriverTestHelpers
* Remove unused LOCAL_CFLAGS
Signed-off-by: Kevin May <kevin.may@arm.com>
Change-Id: I1787f1ed6784b3bbec017536d87d49197405e853
Signed-off-by: Kevin May <kevin.may@arm.com>
diff --git a/1.0/ArmnnDriver.hpp b/1.0/ArmnnDriver.hpp
index 035d448..b18f065 100644
--- a/1.0/ArmnnDriver.hpp
+++ b/1.0/ArmnnDriver.hpp
@@ -46,8 +46,8 @@
return armnn_driver::ArmnnDriverImpl<HalPolicy>::getSupportedOperations(m_Runtime, m_Options, model, cb);
}
- Return<ErrorStatus> prepareModel(const V1_0::Model& model,
- const android::sp<V1_0::IPreparedModelCallback>& cb) override
+ Return<V1_0::ErrorStatus> prepareModel(const V1_0::Model& model,
+ const android::sp<V1_0::IPreparedModelCallback>& cb) override
{
ALOGV("hal_1_0::ArmnnDriver::prepareModel()");
diff --git a/1.0/ArmnnDriverImpl.cpp b/1.0/ArmnnDriverImpl.cpp
index a35bb0e..57f828c 100644
--- a/1.0/ArmnnDriverImpl.cpp
+++ b/1.0/ArmnnDriverImpl.cpp
@@ -43,7 +43,7 @@
capabilities.quantized8Performance.powerUsage =
ParseSystemProperty(g_Quantized8PerformancePowerUsageName, .1f);
- cb(ErrorStatus::NONE, capabilities);
+ cb(V1_0::ErrorStatus::NONE, capabilities);
}
else
{
@@ -52,7 +52,7 @@
capabilities.quantized8Performance.execTime = 0;
capabilities.quantized8Performance.powerUsage = 0;
- cb(ErrorStatus::DEVICE_UNAVAILABLE, capabilities);
+ cb(V1_0::ErrorStatus::DEVICE_UNAVAILABLE, capabilities);
}
return Void();
diff --git a/1.0/ArmnnDriverImpl.hpp b/1.0/ArmnnDriverImpl.hpp
index 7f033e0..bb93e2e 100644
--- a/1.0/ArmnnDriverImpl.hpp
+++ b/1.0/ArmnnDriverImpl.hpp
@@ -11,6 +11,10 @@
#include <armnn/ArmNN.hpp>
+#ifdef ARMNN_ANDROID_R
+using namespace android::nn::hal;
+#endif
+
namespace V1_0 = ::android::hardware::neuralnetworks::V1_0;
namespace armnn_driver