EM-ODP  3.7.0
Event Machine on ODP
queue_elem_t Struct Reference

#include <em_queue_types.h>

Collaboration diagram for queue_elem_t:

Data Fields

uint16_t valid_check
 
union {
   uint8_t   all
 
   struct {
      uint8_t   use_multi_rcv: 1
 
      uint8_t   scheduled: 1
 
      uint8_t   in_atomic_group: 1
 
      uint8_t   is_pktin: 1
 
      uint8_t   rsvd: 4
 
   } 
 
flags
 
queue_state_t state
 
uint8_t priority
 
uint8_t type
 
uint16_t max_events
 
uint16_t eo
 
uint32_t queue
 
odp_queue_t odp_queue
 
void * context
 
union {
   em_receive_func_t   receive_func
 
   em_receive_multi_func_t   receive_multi_func
 
}; 
 
void * eo_ctx
 
union {
   q_elem_atomic_group_t   agrp
 
   q_elem_output_t   output
 
}; 
 
eo_elem_teo_elem
 
em_queue_group_t queue_group
 
list_node_t queue_node
 
list_node_t qgrp_node
 
objpool_elem_t queue_pool_elem
 
void *end[0] ENV_CACHE_LINE_ALIGNED
 

Detailed Description

EM queue element

Definition at line 180 of file em_queue_types.h.

Field Documentation

◆ context

void* queue_elem_t::context

User defined queue context (can be NULL)

Definition at line 231 of file em_queue_types.h.

◆ ENV_CACHE_LINE_ALIGNED

void* end [0] queue_elem_t::ENV_CACHE_LINE_ALIGNED

Guarantee that size is a multiple of cache line size

Definition at line 262 of file em_queue_types.h.

◆ eo

uint16_t queue_elem_t::eo

EM EO that this queue belongs to

Definition at line 222 of file em_queue_types.h.

◆ eo_ctx

void* queue_elem_t::eo_ctx

Copy of the user defined eo context (or NULL) for performance

Definition at line 241 of file em_queue_types.h.

◆ eo_elem

eo_elem_t* queue_elem_t::eo_elem

Associated eo element

Definition at line 249 of file em_queue_types.h.

◆ in_atomic_group

uint8_t queue_elem_t::in_atomic_group

Does this queue belong to an EM Atomic Group (true/false)?

Definition at line 201 of file em_queue_types.h.

◆ is_pktin

uint8_t queue_elem_t::is_pktin

Is this an ODP pktin event queue (true/false)?

Definition at line 203 of file em_queue_types.h.

◆ max_events

uint16_t queue_elem_t::max_events

Max number of events passed to the EO's multi-event receive function

Definition at line 219 of file em_queue_types.h.

◆ odp_queue

odp_queue_t queue_elem_t::odp_queue

Associated ODP queue handle

Definition at line 228 of file em_queue_types.h.

◆ priority

uint8_t queue_elem_t::priority

Queue priority

Definition at line 213 of file em_queue_types.h.

◆ qgrp_node

list_node_t queue_elem_t::qgrp_node

List node for linking queue elems belonging to a queue group

Definition at line 257 of file em_queue_types.h.

◆ queue

uint32_t queue_elem_t::queue

Queue handle

Definition at line 225 of file em_queue_types.h.

◆ queue_group

em_queue_group_t queue_elem_t::queue_group

Queue group handle of this queue

Definition at line 252 of file em_queue_types.h.

◆ queue_node

list_node_t queue_elem_t::queue_node

List node for linking queue elems belonging to an EO

Definition at line 255 of file em_queue_types.h.

◆ queue_pool_elem

objpool_elem_t queue_elem_t::queue_pool_elem

Queue pool elem for linking free queues for queue_alloc()

Definition at line 259 of file em_queue_types.h.

◆ receive_func

em_receive_func_t queue_elem_t::receive_func

Copy of the event receive function for better performance

Definition at line 235 of file em_queue_types.h.

◆ receive_multi_func

em_receive_multi_func_t queue_elem_t::receive_multi_func

Copy of the multi-event receive function for better performance

Definition at line 237 of file em_queue_types.h.

◆ rsvd

uint8_t queue_elem_t::rsvd

reserved bits

Definition at line 205 of file em_queue_types.h.

◆ scheduled

uint8_t queue_elem_t::scheduled

set if queue is scheduled, i.e. atomic, parallel or ordered

Definition at line 199 of file em_queue_types.h.

◆ state

queue_state_t queue_elem_t::state

Queue state

Definition at line 210 of file em_queue_types.h.

◆ type

uint8_t queue_elem_t::type

Atomic, parallel, ordered, unscheduled, local, output

Definition at line 216 of file em_queue_types.h.

◆ valid_check

uint16_t queue_elem_t::valid_check

Check that contents is an EM queue elem.

EM will verify that the ODP queue context actually points to an EM queue elem and not to something else: queue_elem_t *q_elem = odp_queue_context(odp_queue); if (!q_elem || q_elem->valid_check != QUEUE_ELEM_VALID) EM_ERROR(...); Keep first.

Definition at line 191 of file em_queue_types.h.


The documentation for this struct was generated from the following file: