A vector behind a const token, with its elements in one movable cell, and its calls on many threads at once. More...
Go to the source code of this file.
Data Structures | |
| struct | VectorRecord |
| The record of one vector, which its token names. More... | |
| struct | MemoriaVectorCfg |
| Arguments for every mmgr_vector_ entry, each reading only the members it needs. More... | |
| struct | MemoriaVectorNs |
| Type of the vector dispatch table. More... | |
Macros | |
| #define | MMGR_VECTOR_CHUNK_BYTES |
| Bytes of the buffer on the stack that a growth copies the elements through, which a build may set before it includes this header. | |
| #define | MMGR_VECTOR_CLAIM_BITS |
| Asserts that a growth copies at least one byte a chunk. | |
| #define | MMGR_VECTOR_CLAIM_WORDS(limit_) |
| The words of claim bits for a ceiling of limit_ elements. | |
| #define | MemoriaVector(name_, element_, limit_, owner_) |
| Declares a vector of element_ with a ceiling of limit_ elements, its cell counted to owner_. | |
| #define | MMGR_VECTOR_THROUGH(guard_) |
| The movable entries of a guard, as the members of a MemoriaVectorCfg. | |
Functions | |
| EMBED_HOST_DEVICE embed_bool | mmgr_vector_at (const MemoriaVectorCfg *args) |
| Copies the element at args->index to args->dst. | |
| EMBED_HOST_DEVICE embed_bool | mmgr_vector_set (const MemoriaVectorCfg *args) |
| Copies the element at args->src to args->index. | |
| EMBED_HOST_DEVICE embed_bool | mmgr_vector_push_back (const MemoriaVectorCfg *args) |
| Appends the element at args->src. | |
| EMBED_HOST_DEVICE embed_bool | mmgr_vector_pop_back (const MemoriaVectorCfg *args) |
| Removes the last element and copies it to args->dst. | |
| EMBED_HOST_DEVICE size_t | mmgr_vector_size (const MemoriaVectorCfg *args) |
| Returns the count of elements. | |
| EMBED_HOST_DEVICE embed_bool | mmgr_vector_release (const MemoriaVectorCfg *args) |
| Gives the cell of the vector back, and leaves the vector with no element. | |
Variables | |
| static const MemoriaVectorNs | memoria_vector |
| Dispatch table instance named memoria_vector, whose members are the mmgr_vector_ entries. | |
A vector behind a const token, with its elements in one movable cell, and its calls on many threads at once.
Definition in file memoria_vector.h.