HPCToolkit
lush-support.h File Reference
#include <stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <string.h>
Include dependency graph for lush-support.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  lush_agent
 
union  lush_assoc_info_u
 
struct  lush_assoc_info_u::lush_assoc_info_s
 
union  lush_lip
 

Macros

#define lush_metricid_NULL   (-1)
 
#define lush_agentid_NULL   (0)
 
#define MKASSOC1(as, c1)   ( ((as) << 4) | (c1) )
 
#define MKASSOC2(as, c1, c2)   ( ((as) << 4) | (c1) | (c2) )
 
#define lush_assoc_info__set_assoc(x, new_as)   (x).u.as = (new_as)
 
#define lush_assoc_info__set_path_len(x, new_len)   (x).u.len = (new_len)
 
#define LUSH_ASSOC_STR_MAX_LEN   6
 
#define LUSH_ASSOC_INFO_STR_MIN_LEN   (LUSH_ASSOC_STR_MAX_LEN + 26)
 
#define LUSH_LIP_DATA1_SZ   16
 
#define LUSH_LIP_DATA8_SZ   (LUSH_LIP_DATA1_SZ / 8)
 
#define LUSH_LIP_STR_MIN_LEN   (20 * LUSH_LIP_DATA8_SZ) /* 0x + 16 + space */
 

Typedefs

typedef int lush_agentid_t
 
typedef struct lush_agent lush_agent_t
 
typedef struct lush_agent_pool lush_agent_pool_t
 
typedef enum lush_assoc lush_assoc_t
 
typedef union lush_assoc_info_u lush_assoc_info_t
 
typedef union lush_lip lush_lip_t
 

Enumerations

enum  lush_assoc {
  LUSH_ASSOC_CLASS_MASK = 0x0f, LUSH_ASSOC_CLASS_NULL = 0x00, LUSH_ASSOC_CLASS_a_to_0 = 0x01, LUSH_ASSOC_CLASS_a_to_1 = 0x02,
  LUSH_ASSOC_CLASS_1_to_a = 0x04, LUSH_ASSOC_NULL = 0, LUSH_ASSOC_1_to_0 = MKASSOC1(1, LUSH_ASSOC_CLASS_a_to_0), LUSH_ASSOC_M_to_0 = MKASSOC1(2, LUSH_ASSOC_CLASS_a_to_0),
  LUSH_ASSOC_1_to_1, LUSH_ASSOC_M_to_1 = MKASSOC1(4, LUSH_ASSOC_CLASS_a_to_1), LUSH_ASSOC_1_to_M = MKASSOC1(5, LUSH_ASSOC_CLASS_1_to_a), LUSH_ASSOC_0_to_0 = MKASSOC1(10, LUSH_ASSOC_CLASS_a_to_0)
}
 

Functions

static unsigned lush_assoc_class (lush_assoc_t as)
 
static bool lush_assoc_is_a_to_0 (lush_assoc_t as)
 
static bool lush_assoc_is_1_to_a (lush_assoc_t as)
 
static bool lush_assoc_is_a_to_1 (lush_assoc_t as)
 
static uint32_t lush_assoc_info__get_path_len (lush_assoc_info_t x)
 
static lush_assoc_t lush_assoc_info__get_assoc (lush_assoc_info_t x)
 
static bool lush_assoc_info__path_len_eq (lush_assoc_info_t x, lush_assoc_info_t y)
 
static bool lush_assoc_class_eq (lush_assoc_t x, lush_assoc_t y)
 
static bool lush_assoc_info_eq (lush_assoc_info_t x, lush_assoc_info_t y)
 
static bool lush_assoc_info_lt (lush_assoc_info_t x, lush_assoc_info_t y)
 
static bool lush_assoc_info_gt (lush_assoc_info_t x, lush_assoc_info_t y)
 
static bool lush_assoc_info_is_root_note (lush_assoc_info_t x)
 
const char * lush_assoc_tostr (lush_assoc_t as)
 
const char * lush_assoc_info_sprintf (char *str, lush_assoc_info_t as_info)
 
static void lush_lip_init (lush_lip_t *x)
 
static bool lush_lip_eq (const lush_lip_t *x, const lush_lip_t *y)
 
static bool lush_lip_lt (const lush_lip_t *x, const lush_lip_t *y)
 
static bool lush_lip_gt (const lush_lip_t *x, const lush_lip_t *y)
 
const char * lush_lip_sprintf (char *str, const lush_lip_t *x)
 
static uint16_t lush_lip_getLMId (const lush_lip_t *x)
 
static void lush_lip_setLMId (lush_lip_t *x, uint16_t lmId)
 
static uint64_t lush_lip_getLMIP (const lush_lip_t *x)
 
static void lush_lip_setLMIP (lush_lip_t *x, uint64_t lm_ip)
 

Variables

lush_assoc_info_t lush_assoc_info_NULL
 
lush_lip_t lush_lip_NULL
 

Macro Definition Documentation

◆ lush_agentid_NULL

#define lush_agentid_NULL   (0)

Definition at line 98 of file lush-support.h.

◆ lush_assoc_info__set_assoc

#define lush_assoc_info__set_assoc (   x,
  new_as 
)    (x).u.as = (new_as)

Definition at line 264 of file lush-support.h.

◆ lush_assoc_info__set_path_len

#define lush_assoc_info__set_path_len (   x,
  new_len 
)    (x).u.len = (new_len)

Definition at line 276 of file lush-support.h.

◆ LUSH_ASSOC_INFO_STR_MIN_LEN

#define LUSH_ASSOC_INFO_STR_MIN_LEN   (LUSH_ASSOC_STR_MAX_LEN + 26)

Definition at line 295 of file lush-support.h.

◆ LUSH_ASSOC_STR_MAX_LEN

#define LUSH_ASSOC_STR_MAX_LEN   6

Definition at line 289 of file lush-support.h.

◆ LUSH_LIP_DATA1_SZ

#define LUSH_LIP_DATA1_SZ   16

Definition at line 308 of file lush-support.h.

◆ LUSH_LIP_DATA8_SZ

#define LUSH_LIP_DATA8_SZ   (LUSH_LIP_DATA1_SZ / 8)

Definition at line 309 of file lush-support.h.

◆ LUSH_LIP_STR_MIN_LEN

#define LUSH_LIP_STR_MIN_LEN   (20 * LUSH_LIP_DATA8_SZ) /* 0x + 16 + space */

Definition at line 356 of file lush-support.h.

◆ lush_metricid_NULL

#define lush_metricid_NULL   (-1)

Definition at line 87 of file lush-support.h.

◆ MKASSOC1

#define MKASSOC1 (   as,
  c1 
)    ( ((as) << 4) | (c1) )

Definition at line 135 of file lush-support.h.

◆ MKASSOC2

#define MKASSOC2 (   as,
  c1,
  c2 
)    ( ((as) << 4) | (c1) | (c2) )

Definition at line 136 of file lush-support.h.

Typedef Documentation

◆ lush_agent_pool_t

Definition at line 119 of file lush-support.h.

◆ lush_agent_t

typedef struct lush_agent lush_agent_t

Definition at line 106 of file lush-support.h.

◆ lush_agentid_t

typedef int lush_agentid_t

Definition at line 99 of file lush-support.h.

◆ lush_assoc_info_t

Definition at line 167 of file lush-support.h.

◆ lush_assoc_t

typedef enum lush_assoc lush_assoc_t

Definition at line 164 of file lush-support.h.

◆ lush_lip_t

typedef union lush_lip lush_lip_t

Definition at line 305 of file lush-support.h.

Enumeration Type Documentation

◆ lush_assoc

enum lush_assoc
Enumerator
LUSH_ASSOC_CLASS_MASK 
LUSH_ASSOC_CLASS_NULL 
LUSH_ASSOC_CLASS_a_to_0 
LUSH_ASSOC_CLASS_a_to_1 
LUSH_ASSOC_CLASS_1_to_a 
LUSH_ASSOC_NULL 
LUSH_ASSOC_1_to_0 
LUSH_ASSOC_M_to_0 
LUSH_ASSOC_1_to_1 
LUSH_ASSOC_M_to_1 
LUSH_ASSOC_1_to_M 
LUSH_ASSOC_0_to_0 

Definition at line 133 of file lush-support.h.

Function Documentation

◆ lush_assoc_class()

static unsigned lush_assoc_class ( lush_assoc_t  as)
inlinestatic

Definition at line 185 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_assoc_class_eq()

static bool lush_assoc_class_eq ( lush_assoc_t  x,
lush_assoc_t  y 
)
inlinestatic

Definition at line 230 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_info__get_assoc()

static lush_assoc_t lush_assoc_info__get_assoc ( lush_assoc_info_t  x)
inlinestatic

Definition at line 215 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_assoc_info__get_path_len()

static uint32_t lush_assoc_info__get_path_len ( lush_assoc_info_t  x)
inlinestatic

Definition at line 209 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_assoc_info__path_len_eq()

static bool lush_assoc_info__path_len_eq ( lush_assoc_info_t  x,
lush_assoc_info_t  y 
)
inlinestatic

Definition at line 224 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_info_eq()

static bool lush_assoc_info_eq ( lush_assoc_info_t  x,
lush_assoc_info_t  y 
)
inlinestatic

Definition at line 237 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_info_gt()

static bool lush_assoc_info_gt ( lush_assoc_info_t  x,
lush_assoc_info_t  y 
)
inlinestatic

Definition at line 252 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_info_is_root_note()

static bool lush_assoc_info_is_root_note ( lush_assoc_info_t  x)
inlinestatic

Definition at line 283 of file lush-support.h.

◆ lush_assoc_info_lt()

static bool lush_assoc_info_lt ( lush_assoc_info_t  x,
lush_assoc_info_t  y 
)
inlinestatic

Definition at line 243 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_info_sprintf()

const char* lush_assoc_info_sprintf ( char *  str,
lush_assoc_info_t  as_info 
)

Definition at line 101 of file lush-support.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_is_1_to_a()

static bool lush_assoc_is_1_to_a ( lush_assoc_t  as)
inlinestatic

Definition at line 197 of file lush-support.h.

Here is the call graph for this function:

◆ lush_assoc_is_a_to_0()

static bool lush_assoc_is_a_to_0 ( lush_assoc_t  as)
inlinestatic

Definition at line 191 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_is_a_to_1()

static bool lush_assoc_is_a_to_1 ( lush_assoc_t  as)
inlinestatic

Definition at line 203 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_assoc_tostr()

const char* lush_assoc_tostr ( lush_assoc_t  as)

Definition at line 86 of file lush-support.c.

Here is the caller graph for this function:

◆ lush_lip_eq()

static bool lush_lip_eq ( const lush_lip_t x,
const lush_lip_t y 
)
inlinestatic

Definition at line 327 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_getLMId()

static uint16_t lush_lip_getLMId ( const lush_lip_t x)
inlinestatic

Definition at line 367 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_getLMIP()

static uint64_t lush_lip_getLMIP ( const lush_lip_t x)
inlinestatic

Definition at line 381 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_gt()

static bool lush_lip_gt ( const lush_lip_t x,
const lush_lip_t y 
)
inlinestatic

Definition at line 351 of file lush-support.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ lush_lip_init()

static void lush_lip_init ( lush_lip_t x)
inlinestatic

Definition at line 319 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_lt()

static bool lush_lip_lt ( const lush_lip_t x,
const lush_lip_t y 
)
inlinestatic

Definition at line 335 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_setLMId()

static void lush_lip_setLMId ( lush_lip_t x,
uint16_t  lmId 
)
inlinestatic

Definition at line 374 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_setLMIP()

static void lush_lip_setLMIP ( lush_lip_t x,
uint64_t  lm_ip 
)
inlinestatic

Definition at line 388 of file lush-support.h.

Here is the caller graph for this function:

◆ lush_lip_sprintf()

const char* lush_lip_sprintf ( char *  str,
const lush_lip_t x 
)

Definition at line 122 of file lush-support.c.

Here is the caller graph for this function:

Variable Documentation

◆ lush_assoc_info_NULL

lush_assoc_info_t lush_assoc_info_NULL

Definition at line 83 of file lush-support.c.

◆ lush_lip_NULL

lush_lip_t lush_lip_NULL

Definition at line 119 of file lush-support.c.