ArmNN
 25.11
Loading...
Searching...
No Matches
ExecutionFrame.hpp
Go to the documentation of this file.
1//
2// Copyright © 2019-2021,2023 Arm Ltd and Contributors. All rights reserved.
3// SPDX-License-Identifier: MIT
4//
5
6#pragma once
7
9
10namespace armnn
11{
12
13using WorkloadQueue = std::vector< std::unique_ptr<IWorkload> >;
14
15/// ExecutionFrame interface to enqueue a workload computation.
17{
18
19public:
20 virtual ~IExecutionFrame() {}
21
22 virtual IExecutionFrame* ExecuteWorkloads(IExecutionFrame* previousFrame) = 0;
23 virtual void PostAllocationConfigure() {};
25};
26
28{
29public:
31
32 IExecutionFrame* ExecuteWorkloads(IExecutionFrame* previousFrame) override ;
33 void PostAllocationConfigure() override;
34 void RegisterDebugCallback(const DebugCallbackFunction& func) override ;
35 void AddWorkloadToQueue(std::unique_ptr<IWorkload> workload);
36 void SetNextExecutionFrame(IExecutionFrame* nextExecutionFrame);
37private:
38 WorkloadQueue m_WorkloadQueue;
39 IExecutionFrame* m_NextExecutionFrame = nullptr;
40};
41
42}
IExecutionFrame * ExecuteWorkloads(IExecutionFrame *previousFrame) override
void AddWorkloadToQueue(std::unique_ptr< IWorkload > workload)
void SetNextExecutionFrame(IExecutionFrame *nextExecutionFrame)
void PostAllocationConfigure() override
void RegisterDebugCallback(const DebugCallbackFunction &func) override
ExecutionFrame interface to enqueue a workload computation.
virtual IExecutionFrame * ExecuteWorkloads(IExecutionFrame *previousFrame)=0
virtual void RegisterDebugCallback(const DebugCallbackFunction &)
virtual void PostAllocationConfigure()
Copyright (c) 2021 ARM Limited and Contributors.
std::function< void(LayerGuid guid, unsigned int slotIndex, ITensorHandle *tensorHandle)> DebugCallbackFunction
Define the type of callback for the Debug layer to call.
Definition Types.hpp:400
std::vector< std::unique_ptr< IWorkload > > WorkloadQueue