function lfds710_queue_bmm_dequeue

From liblfds.org
Jump to navigation Jump to search

Source Files

└───liblfds710
    ├───inc
    │   └───liblfds710
    │           lfds710_queue_bmm.h
    └───src
        └───lfds710_queue
                lfds710_queue_bmm_dequeue.c

Opaque Structures

struct lfds710_queue_bmm_state;

Prototype

int lfds710_queue_bmm_dequeue( struct lfds710_queue_bmm_state *qbmms, void **key, void **value );

Parameters

struct lfds710_queue_bmm_state *qbmms

A pointer to an initialized struct lfds710_queue_bmm_state.

void **key

A pointer to a void pointer, which is set to the key of the dequeued element. This argument can be NULL.

void **value

A pointer to a void pointer, which is set to the value of the dequeued element. This argument can be NULL.

Return Value

Returns 1 on a successful dequeue. Returns 0 if dequeing failed. Dequeuing only fails if the queue is empty.

Notes

Remember that this is a relaxed data structure, so enqueues and dequeues performed on any given logical core may well not be seen immediately by other logical cores; so as such for example a queue which according to programme logic must have items enqueued due to queue operations may for a short period after those enqueue operations still be seen as empty on other logical cores.

See Also