1 // 2 // Copyright © 2017 Arm Ltd. All rights reserved. 3 // SPDX-License-Identifier: MIT 4 // 5 6 #pragma once 7 8 #include <armnn/backends/profiling/IBackendProfiling.hpp> 9 #include "ICounterDirectory.hpp" 10 11 namespace armnn 12 { 13 14 namespace profiling 15 { 16 17 class ISendCounterPacket 18 { 19 public: 20 using IndexValuePairsVector = std::vector<CounterValue>; 21 ~ISendCounterPacket()22 virtual ~ISendCounterPacket() {} 23 24 /// Create and write a StreamMetaDataPacket in the buffer 25 virtual void SendStreamMetaDataPacket() = 0; 26 27 /// Create and write a CounterDirectoryPacket from the parameters to the buffer. 28 virtual void SendCounterDirectoryPacket(const ICounterDirectory& counterDirectory) = 0; 29 30 /// Create and write a PeriodicCounterCapturePacket from the parameters to the buffer. 31 virtual void SendPeriodicCounterCapturePacket(uint64_t timestamp, const IndexValuePairsVector& values) = 0; 32 33 /// Create and write a PeriodicCounterSelectionPacket from the parameters to the buffer. 34 virtual void SendPeriodicCounterSelectionPacket(uint32_t capturePeriod, 35 const std::vector<uint16_t>& selectedCounterIds) = 0; 36 }; 37 38 } // namespace profiling 39 40 } // namespace armnn 41 42