aboutsummaryrefslogtreecommitdiff
path: root/test/DriverTestHelpers.hpp
diff options
context:
space:
mode:
authorSadik Armagan <sadik.armagan@arm.com>2021-02-12 17:16:42 +0000
committerKevin May <kevin.may@arm.com>2021-02-15 16:50:24 +0000
commit188675fd7e7239f56212d72f8ac10598de87e76a (patch)
tree611876f7c43f81c88b8dec19ae86afcb6d6a1a64 /test/DriverTestHelpers.hpp
parentcd639c98c347c1addae8c65eb1f4d8e75b468fdb (diff)
downloadandroid-nn-driver-188675fd7e7239f56212d72f8ac10598de87e76a.tar.gz
IVGCVSW-5665 Basic NN Driver support for next OS Version
Signed-off-by: Kevin May <kevin.may@arm.com> Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: I1e1db52322092c6b1b7ac6183c3adc90aabcec24
Diffstat (limited to 'test/DriverTestHelpers.hpp')
-rw-r--r--test/DriverTestHelpers.hpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/test/DriverTestHelpers.hpp b/test/DriverTestHelpers.hpp
index 05b78925..d37fbf26 100644
--- a/test/DriverTestHelpers.hpp
+++ b/test/DriverTestHelpers.hpp
@@ -14,8 +14,11 @@
#include <android/hidl/allocator/1.0/IAllocator.h>
+using RequestArgument = V1_0::RequestArgument;
using ::android::hidl::allocator::V1_0::IAllocator;
+using ::android::hidl::memory::V1_0::IMemory;
+
namespace android
{
namespace hardware
@@ -202,7 +205,7 @@ void AddBoolOperand(HalModel& model, bool value, uint32_t numberOfConsumers = 1)
using HalOperandType = typename HalPolicy::OperandType;
using HalOperandLifeTime = typename HalPolicy::OperandLifeTime;
- DataLocation location = {};
+ V1_0::DataLocation location = {};
location.offset = model.operandValues.size();
location.length = sizeof(uint8_t);
@@ -420,7 +423,7 @@ void AddTensorOperand(HalModel& model,
totalElements *= dim;
}
- DataLocation location = {};
+ V1_0::DataLocation location = {};
location.length = totalElements * sizeof(T);
if(operandLifeTime == HalOperandLifeTime::CONSTANT_COPY)
@@ -477,7 +480,7 @@ void AddIntOperand(HalModel& model, int32_t value, uint32_t numberOfConsumers =
using HalOperandType = typename HalPolicy::OperandType;
using HalOperandLifeTime = typename HalPolicy::OperandLifeTime;
- DataLocation location = {};
+ V1_0::DataLocation location = {};
location.offset = model.operandValues.size();
location.length = sizeof(int32_t);
@@ -503,7 +506,7 @@ void AddFloatOperand(HalModel& model,
using HalOperandType = typename HalPolicy::OperandType;
using HalOperandLifeTime = typename HalPolicy::OperandLifeTime;
- DataLocation location = {};
+ V1_0::DataLocation location = {};
location.offset = model.operandValues.size();
location.length = sizeof(float);