#include <lsmp_int.hh>
Public Attributes | |
| int | status |
| int | version |
| LSMP version number. | |
| int | gbl_count |
| Number of times partition was accessed. | |
| int | gbl_semid |
| Global semaphore ID. | |
| int | nbuf |
| Number of buffer in partition. | |
| int | lbuf |
| Buffer data length. | |
| LSMP_BufferQ | full |
| Full buffer list. | |
| LSMP_BufferQ | free |
| Free buffer list. | |
| char | name [LSMP_LNAME] |
| Partition name. | |
| int | ncons |
| Number of active consumers. | |
| int | con_semid [LSMP_LMASK] |
| Consumer semaphore IDs. | |
| ConFlags | conmask |
| Consumer use masks. | |
The shared memory global class contains the constrol and status held in the shared memory partition.
The status flags control the buffer allocation policy. The default policy is to allocate buffers from the free list only and to release a buffer only when it is not reserved, is not in use and has been seen by at least one consumer. The policy modification bits are as follows:
RELBUF | A buffer is released if no consumers have reserved it, even if it has not been seen. |
SCAVAGE | The oldest unused and unreserved buffer may be allocated from the full queue. Unused buffers are not returned to the free queue. |
RQSYNCH | No buffer may be allocated by a producer unless there is a consumer waiting. |
KEEP | Don't delete the partition when the global access count goes to zero. |
EXPOSE | All buffers will be automatically reserved by all current consumers. |
1.5.4