ArmNN
NotReleased
|
#include "ProfilingTestUtils.hpp"
#include "ProfilingUtils.hpp"
#include <armnn/Descriptors.hpp>
#include <LabelsAndEventClasses.hpp>
#include <ProfilingService.hpp>
#include <boost/test/unit_test.hpp>
Go to the source code of this file.
Functions | |
unsigned int | OffsetToNextWord (unsigned int numberOfBytes) |
void | VerifyTimelineLabelBinaryPacket (Optional< ProfilingGuid > guid, const std::string &label, const unsigned char *readableData, unsigned int &offset) |
void | VerifyTimelineEventClassBinaryPacket (ProfilingGuid guid, const unsigned char *readableData, unsigned int &offset) |
void | VerifyTimelineRelationshipBinaryPacket (ProfilingRelationshipType relationshipType, Optional< ProfilingGuid > relationshipGuid, Optional< ProfilingGuid > headGuid, Optional< ProfilingGuid > tailGuid, const unsigned char *readableData, unsigned int &offset) |
void | VerifyTimelineEntityBinaryPacket (Optional< ProfilingGuid > guid, const unsigned char *readableData, unsigned int &offset) |
void | VerifyTimelineEventBinaryPacket (Optional< uint64_t > timestamp, Optional< std::thread::id > threadId, Optional< ProfilingGuid > eventGuid, const unsigned char *readableData, unsigned int &offset) |
void | VerifyPostOptimisationStructureTestImpl (armnn::BackendId backendId) |
|
inline |
Definition at line 15 of file ProfilingTestUtils.cpp.
References armnn::profiling::uint32_t_size.
Referenced by VerifyTimelineLabelBinaryPacket().
void VerifyPostOptimisationStructureTestImpl | ( | armnn::BackendId | backendId | ) |
Definition at line 355 of file ProfilingTestUtils.cpp.
References LabelsAndEventClasses::ARMNN_PROFILING_EOL_EVENT_CLASS, LabelsAndEventClasses::ARMNN_PROFILING_SOL_EVENT_CLASS, LabelsAndEventClasses::BACKENDID_GUID, BOOST_CHECK(), ProfilingService::ConfigureProfilingService(), IOutputSlot::Connect(), LabelsAndEventClasses::CONNECTION_GUID, INetwork::Create(), IRuntime::Create(), DataLink, ExecutionLink, armnn::Float32, BackendId::Get(), IConnectableLayer::GetGuid(), IConnectableLayer::GetInputSlot(), IConnectableLayer::GetOutputSlot(), BufferManager::GetReadableBuffer(), LabelsAndEventClasses::INFERENCE_GUID, ProfilingService::Instance(), LabelLink, Convolution2dDescriptor::m_BiasEnabled, IRuntime::CreationOptions::ExternalProfilingOptions::m_EnableProfiling, Convolution2dDescriptor::m_PadBottom, Convolution2dDescriptor::m_PadLeft, Convolution2dDescriptor::m_PadRight, Convolution2dDescriptor::m_PadTop, IRuntime::CreationOptions::m_ProfilingOptions, Convolution2dDescriptor::m_StrideX, Convolution2dDescriptor::m_StrideY, BufferManager::MarkRead(), LabelsAndEventClasses::NAME_GUID, armnn::Optimize(), options, profilingService, RetentionLink, IOutputSlot::SetTensorInfo(), armnn::Success, LabelsAndEventClasses::TYPE_GUID, VerifyTimelineEntityBinaryPacket(), VerifyTimelineEventBinaryPacket(), VerifyTimelineLabelBinaryPacket(), VerifyTimelineRelationshipBinaryPacket(), and LabelsAndEventClasses::WORKLOAD_EXECUTION_GUID.
Referenced by BOOST_AUTO_TEST_CASE().
void VerifyTimelineEntityBinaryPacket | ( | Optional< ProfilingGuid > | guid, |
const unsigned char * | readableData, | ||
unsigned int & | offset | ||
) |
Definition at line 228 of file ProfilingTestUtils.cpp.
References BOOST_CHECK(), OptionalBase::has_value(), armnn::profiling::ReadUint32(), armnn::profiling::ReadUint64(), armnn::profiling::uint32_t_size, and OptionalReferenceSwitch< std::is_reference< T >::value, T >::value().
Referenced by BOOST_AUTO_TEST_CASE(), and VerifyPostOptimisationStructureTestImpl().
void VerifyTimelineEventBinaryPacket | ( | Optional< uint64_t > | timestamp, |
Optional< std::thread::id > | threadId, | ||
Optional< ProfilingGuid > | eventGuid, | ||
const unsigned char * | readableData, | ||
unsigned int & | offset | ||
) |
Definition at line 278 of file ProfilingTestUtils.cpp.
References BOOST_CHECK(), OptionalBase::has_value(), armnn::profiling::ReadBytes(), armnn::profiling::ReadUint32(), armnn::profiling::ReadUint64(), armnn::profiling::uint32_t_size, and OptionalReferenceSwitch< std::is_reference< T >::value, T >::value().
Referenced by BOOST_AUTO_TEST_CASE(), and VerifyPostOptimisationStructureTestImpl().
void VerifyTimelineEventClassBinaryPacket | ( | ProfilingGuid | guid, |
const unsigned char * | readableData, | ||
unsigned int & | offset | ||
) |
Definition at line 88 of file ProfilingTestUtils.cpp.
References BOOST_CHECK(), armnn::profiling::ReadUint32(), armnn::profiling::ReadUint64(), and armnn::profiling::uint32_t_size.
Referenced by BOOST_AUTO_TEST_CASE().
void VerifyTimelineLabelBinaryPacket | ( | Optional< ProfilingGuid > | guid, |
const std::string & | label, | ||
const unsigned char * | readableData, | ||
unsigned int & | offset | ||
) |
Definition at line 28 of file ProfilingTestUtils.cpp.
References BOOST_CHECK(), OptionalBase::has_value(), OffsetToNextWord(), armnn::profiling::ReadUint32(), armnn::profiling::ReadUint64(), armnn::profiling::uint32_t_size, and OptionalReferenceSwitch< std::is_reference< T >::value, T >::value().
Referenced by BOOST_AUTO_TEST_CASE(), and VerifyPostOptimisationStructureTestImpl().
void VerifyTimelineRelationshipBinaryPacket | ( | ProfilingRelationshipType | relationshipType, |
Optional< ProfilingGuid > | relationshipGuid, | ||
Optional< ProfilingGuid > | headGuid, | ||
Optional< ProfilingGuid > | tailGuid, | ||
const unsigned char * | readableData, | ||
unsigned int & | offset | ||
) |
Definition at line 129 of file ProfilingTestUtils.cpp.
References BOOST_CHECK(), DataLink, ExecutionLink, OptionalBase::has_value(), LabelLink, armnn::profiling::ReadUint32(), armnn::profiling::ReadUint64(), RetentionLink, armnn::profiling::uint32_t_size, and OptionalReferenceSwitch< std::is_reference< T >::value, T >::value().
Referenced by BOOST_AUTO_TEST_CASE(), and VerifyPostOptimisationStructureTestImpl().