blob: b4bd615bab10aba754de4d4b39b7dcfc4278ca9a [file] [log] [blame]
Narumol Prangnawarat404b2752019-09-24 17:23:16 +01001//
2// Copyright © 2019 Arm Ltd. All rights reserved.
3// SPDX-License-Identifier: MIT
4//
5
6#pragma once
7
8namespace armnn
9{
10
11namespace profiling
12{
13
14class IReadOnlyPacketBuffer // interface used by the read thread
15{
16public:
17 virtual ~IReadOnlyPacketBuffer() {}
18
19 virtual const unsigned char* const GetReadableData() const = 0;
20
21 virtual unsigned int GetSize() const = 0;
22
23 virtual void MarkRead() = 0;
24};
25
26class IPacketBuffer : public IReadOnlyPacketBuffer // interface used by code that writes binary packets
27{
28public:
29 virtual ~IPacketBuffer() {}
30
31 virtual void Commit(unsigned int size) = 0;
32
33 virtual void Release() = 0;
34
35 virtual unsigned char* GetWritableData() = 0;
36};
37
38} // namespace profiling
39
40} // namespace armnn