blob: 991ab45396bdb0645330fcfa01a347afe3fbc573 [file] [log] [blame]
Ryan OSheaf4bfa6a2020-06-10 11:33:37 +01001//
2// Copyright © 2020 Arm Ltd and Contributors. All rights reserved.
3// SPDX-License-Identifier: MIT
4//
5
6#include "RefFillWorkload.hpp"
7#include "Fill.hpp"
8
9#include "Decoders.hpp"
10#include "Encoders.hpp"
11#include "RefWorkloadUtils.hpp"
12#include "Profiling.hpp"
13
14namespace armnn
15{
16
17void RefFillWorkload::Execute() const
18{
19 ARMNN_SCOPED_PROFILING_EVENT(Compute::CpuRef, "RefFillWorkload_Execute");
20
21 const TensorInfo &outputTensorInfo = GetTensorInfo(m_Data.m_Outputs[0]);
22
23 std::unique_ptr<Encoder<float>> encoderPtr = MakeEncoder<float>(outputTensorInfo, m_Data.m_Outputs[0]->Map());
24 Encoder<float> &encoder = *encoderPtr;
25
26 Fill(encoder, outputTensorInfo.GetShape(), m_Data.m_Parameters.m_Value);
27}
28
29} //namespace armnn