ArmNN
 25.11
Loading...
Searching...
No Matches
ExecutionFrame.cpp
Go to the documentation of this file.
1//
2// Copyright © 2017 Arm Ltd. All rights reserved.
3// SPDX-License-Identifier: MIT
4//
5
6#include "ExecutionFrame.hpp"
7
8using namespace std;
9
10namespace armnn
11{
13
15{
16 IgnoreUnused(previousFrame);
17 for (auto& workload: m_WorkloadQueue)
18 {
19 workload->Execute();
20 }
21 return m_NextExecutionFrame;
22}
23
25{
26 for (auto&& workloadPtr: m_WorkloadQueue)
27 {
28 workloadPtr.get()->PostAllocationConfigure();
29 }
30}
31
33{
34 for (auto&& workloadPtr: m_WorkloadQueue)
35 {
36 workloadPtr.get()->RegisterDebugCallback(func);
37 }
38}
39
40void ExecutionFrame::AddWorkloadToQueue(std::unique_ptr<IWorkload> workload)
41{
42 m_WorkloadQueue.push_back(std::move(workload));
43}
44
46{
47 m_NextExecutionFrame = nextExecutionFrame;
48}
49
50}
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.
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
void IgnoreUnused(Ts &&...)