FD.io VPP  v17.10-9-gd594711
Vector Packet Processing
smp.h File Reference
+ Include dependency graph for smp.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define clib_smp_compare_and_swap(addr, new, old)   __sync_val_compare_and_swap(addr,old,new)
 
#define clib_smp_swap(addr, new)   __sync_lock_test_and_set(addr,new)
 
#define clib_smp_atomic_add(addr, increment)   __sync_fetch_and_add(addr,increment)
 
#define clib_smp_pause()   do { asm volatile ("pause"); } while (0)
 

Functions

static void os_sched_yield (void)
 

Macro Definition Documentation

#define clib_smp_atomic_add (   addr,
  increment 
)    __sync_fetch_and_add(addr,increment)

Definition at line 46 of file smp.h.

#define clib_smp_compare_and_swap (   addr,
  new,
  old 
)    __sync_val_compare_and_swap(addr,old,new)

Definition at line 44 of file smp.h.

#define clib_smp_pause ( )    do { asm volatile ("pause"); } while (0)

Definition at line 49 of file smp.h.

#define clib_smp_swap (   addr,
  new 
)    __sync_lock_test_and_set(addr,new)

Definition at line 45 of file smp.h.

Function Documentation

static void os_sched_yield ( void  )
inlinestatic

Definition at line 60 of file smp.h.