From 4de83c5a6a57d0468d9f2f854c94bc4a760b66b6 Mon Sep 17 00:00:00 2001 From: Derek Lamberti Date: Tue, 17 Mar 2020 13:40:18 +0000 Subject: Less code duplication in HAL 1.2 Signed-off-by: Derek Lamberti Change-Id: Ic2e8964745a4323efb1e06d466c0699f17a70c55 --- ArmnnPreparedModel.hpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'ArmnnPreparedModel.hpp') diff --git a/ArmnnPreparedModel.hpp b/ArmnnPreparedModel.hpp index 270a9339..89f6226f 100644 --- a/ArmnnPreparedModel.hpp +++ b/ArmnnPreparedModel.hpp @@ -24,6 +24,10 @@ struct ArmnnCallback_1_0 armnnExecuteCallback_1_0 callback; }; +struct ExecutionContext_1_0 {}; + +using CallbackContext_1_0 = CallbackContext; + template class ArmnnPreparedModel : public V1_0::IPreparedModel { @@ -43,9 +47,9 @@ public: /// execute the graph prepared from the request void ExecuteGraph(std::shared_ptr>& pMemPools, - std::shared_ptr& pInputTensors, - std::shared_ptr& pOutputTensors, - ArmnnCallback_1_0 callback); + armnn::InputTensors& inputTensors, + armnn::OutputTensors& outputTensors, + CallbackContext_1_0 callback); /// Executes this model with dummy inputs (e.g. all zeroes). /// \return false on failure, otherwise true @@ -60,7 +64,7 @@ private: HalModel m_Model; // There must be a single RequestThread for all ArmnnPreparedModel objects to ensure serial execution of workloads // It is specific to this class, so it is declared as static here - static RequestThread m_RequestThread; + static RequestThread m_RequestThread; uint32_t m_RequestCount; const std::string& m_RequestInputsAndOutputsDumpDir; const bool m_GpuProfilingEnabled; -- cgit v1.2.1