blob: 1a97ca741ce429a57107619b754c7b53e34e53ed (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
//
// Copyright © 2019 Arm Ltd. All rights reserved.
// SPDX-License-Identifier: MIT
//
#pragma once
#include <memory>
namespace armnn
{
namespace profiling
{
class IReadOnlyPacketBuffer // interface used by the read thread
{
public:
virtual ~IReadOnlyPacketBuffer() {}
virtual const unsigned char* GetReadableData() const = 0;
virtual unsigned int GetSize() const = 0;
virtual void MarkRead() = 0;
};
class IPacketBuffer : public IReadOnlyPacketBuffer // interface used by code that writes binary packets
{
public:
virtual ~IPacketBuffer() {}
virtual void Commit(unsigned int size) = 0;
virtual void Release() = 0;
virtual unsigned char* GetWritableData() = 0;
};
using IPacketBufferPtr = std::unique_ptr<IPacketBuffer>;
} // namespace profiling
} // namespace armnn
|