ArmNN
 25.02
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
RefReshapeWorkload.cpp
Go to the documentation of this file.
1 //
2 // Copyright © 2018-2024 Arm Ltd and Contributors. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 
6 #include "RefReshapeWorkload.hpp"
7 #include "RefWorkloadUtils.hpp"
8 #include "Profiling.hpp"
9 
10 #include <cstring>
11 
12 namespace armnn
13 {
14 
16 {
18 }
19 
20 void RefReshapeWorkload::Execute(std::vector<ITensorHandle*> inputs, std::vector<ITensorHandle*> outputs) const
21 {
22  ARMNN_SCOPED_PROFILING_EVENT_REF_NAME_GUID("RefReshapeWorkload_Execute");
23 
24  void* output = outputs[0]->Map();
25  const void* input = inputs[0]->Map();
26  unsigned int numBytes = GetTensorInfo(inputs[0]).GetNumBytes();
27  memcpy(output, input, numBytes);
28 }
29 
30 } //namespace armnn
#define ARMNN_SCOPED_PROFILING_EVENT_REF_NAME_GUID(label)
Creates a profiling event that uses GetGuid() and GetName() from the calling class.
QueueDescriptor m_Data
Definition: Workload.hpp:74
void Execute() const override
unsigned int GetNumBytes() const
Definition: Tensor.cpp:427
Copyright (c) 2021 ARM Limited and Contributors.
const TensorInfo & GetTensorInfo(const ITensorHandle *tensorHandle)
float32 helpers
std::vector< ITensorHandle * > m_Inputs
std::vector< ITensorHandle * > m_Outputs