Template Class Buffer¶
- Defined in File buffer.h
Class Documentation¶
-
template <typename EntryType, typename DataStructure>
classBuffer
¶ The Buffer utility.
Buffer used to agregate data transfers in insertion methods. It is associated to a DataStructure instance, through its global object identifier, and to the Locality target of the data transfers.
- Template Parameters
EntryType
: type of the entries stored in the buffer.DataStructure
: DataStructure using the buffer.
Public Types
-
template<>
usingEntriesArray
= std::array<EntryType, kBufferSize>¶
Public Functions
-
Buffer
()¶
-
Buffer
(const rt::Locality &loc, const ObjectIdentifier<DataStructure> &oid)¶
-
void
FlushBuffer
()¶
-
void
Insert
(const EntryType entry)¶
-
void
Insert
(const EntryType *entry, const size_t num_entries)¶
Public Static Attributes
-
constexpr size_t
kBufferSize
=
constants::max(constants::kBufferNumBytes / sizeof(EntryType), 1lu)
¶ Size of the buffer in terms of number of entries.
Protected Functions
-
Buffer
(const ObjectIdentifier<DataStructure> &oid)¶
-
struct
FlushArgs
¶ Public Members
-
template<>
EntriesArraydata
¶
-
template<>
size_tnumEntries
¶
-
template<>
ObjectIdentifier<DataStructure>oid
¶
-
template<>