FARGOS/VISTA Object Management Environment Core
..
|
These classes manage a region of memory, represented by a BufferRegion, into a collection of blocks. The CircularBufferManager turns the region into strict a FIFO circular buffer of blocks. The FixedBufferManager allocates blocks without imposing a strict order. More...
Classes | |
struct | SharedBufferRegionHeader_32 |
Region header for a 32-bit shared memory segment. More... | |
struct | SharedBufferRegionHeader_64 |
Region header for a 64-bit shared memory segment. More... | |
struct | SharedBufferAllocRecord_32 |
Allocation record for chains in a 32-bit shared memory buffer. More... | |
struct | SharedBufferAllocRecord_64 |
Allocation record for chains in a 64-bit shared memory buffer. More... | |
class | BufferRegion |
Interface to a buffer region. This is an abstract class. More... | |
class | CircularBufferManager |
Impose a circular buffer on a BufferRegion. More... | |
class | FixedBufferManager |
Impose a fixed-size buffer on a BufferRegion. More... | |
Macros | |
#define | DEFAULT_CIRCULAR_BFR_MAGIC_NUMBER "CIRCBFR" |
Magic number to identify a shared memory circular buffer. More... | |
#define | DEFAULT_FIXED_BFR_MAGIC_NUMBER "FIXDBFR" |
Magic number to identify a fixed-size memory buffer. More... | |
#define | SHARED_BUFFER_OFFSET_SIZE 4 |
Typedefs | |
typedef uint32_t | SharedBuffer_Offset_t |
typedef SharedBufferRegionHeader_32 | SharedBufferRegionHeader |
Default SharedBufferRegionHeader. More... | |
typedef SharedBufferAllocRecord_32 | SharedBufferAllocRecord |
Default SharedBufferAllocRecord. More... | |
Functions | |
bool | sharedBufferSegmentIsInNativeByteOrder (const void *segment) |
Indicates if segment uses native byte order. More... | |
bool | sharedBufferSegmentSizeIs64bit (const void *segment) |
Indicates if segment uses 64-bit offsets. More... | |
void | waitForBufferAllocRecordToBeReady (SharedBufferAllocRecord *rec) |
Verify record is prepared and, if needed, wait until it is prepared. More... | |
These classes manage a region of memory, represented by a BufferRegion, into a collection of blocks. The CircularBufferManager turns the region into strict a FIFO circular buffer of blocks. The FixedBufferManager allocates blocks without imposing a strict order.
#define DEFAULT_CIRCULAR_BFR_MAGIC_NUMBER "CIRCBFR" |
Magic number to identify a shared memory circular buffer.
#define DEFAULT_FIXED_BFR_MAGIC_NUMBER "FIXDBFR" |
Magic number to identify a fixed-size memory buffer.
#define SHARED_BUFFER_OFFSET_SIZE 4 |
typedef uint32_t SharedBuffer_Offset_t |
Default SharedBufferAllocRecord.
Default SharedBufferRegionHeader.
|
inline |
Indicates if segment uses native byte order.
Referenced by BufferRegion::getActiveListHead(), BufferRegion::getFreeListHead(), SharedMemoryVariableManager::iterateOver32BitSegment(), SharedMemoryVariableManager::iterateOver64BitSegment(), and BufferRegion::traverseNextBlock().
|
inline |
Indicates if segment uses 64-bit offsets.
Referenced by BufferRegion::getActiveListHead(), BufferRegion::getFreeListHead(), and BufferRegion::traverseNextBlock().
void waitForBufferAllocRecordToBeReady | ( | SharedBufferAllocRecord * | rec | ) |
Verify record is prepared and, if needed, wait until it is prepared.
rec | points to the SharedBufferAllocRecord to be examined. |
Since many usage scenarios involve separate consumer and processing threads, it is possible to a processing thread to become aware of the existence of a buffer record before it is completed prepared. The last step of record preparation is to set the usedLen field to the proper length.
References OME_EXPECT_FALSE, OME_YIELD_THREAD, and SharedBufferAllocRecord_32::usedLen.
Referenced by LogManager::commitLogRecord(), and IO_Processor::doProcessLoop().
![]() | Generated: Fri Jul 31 2020 18:19:16
Support Information |