Go to the documentation of this file.
117 va_start(varg_list, config);
128 int int_val = va_arg(varg_list,
int);
134 double double_val = va_arg(varg_list,
double);
141 void *ptr_val = va_arg(varg_list,
void *);
207 va_start(varg_list, num_vars);
208 for (idx = 0; idx < num_vars; idx++) {
209 void *ptr = va_arg(varg_list,
void *);
260 int idx,
void *p_val)
271 if (p_element->
idx == idx) {
272 memcpy(p_val, p_element->
val,
276 p_element = p_element->
p_next;
302 if (p_element->
idx == idx) {
304 p_element->
type = type;
307 }
else if (!p_element->
p_next) {
311 (
void **)&p_new_element);
313 p_new_element->idx = idx;
314 p_new_element->type = type;
316 p_element->
p_next = p_new_element;
319 p_element = p_element->
p_next;
347 return sizeof(double);
349 return sizeof(
void *);
A struct that sets and gets a scheduler configuration.
#define ABTI_SCHED_CONFIG_HTABLE_SIZE
char val[sizeof(double) > sizeof(void *) ? sizeof(double) :sizeof(void *)]
ABTI_sched_config_element elements[ABTI_SCHED_CONFIG_HTABLE_SIZE]
#define ABT_ERR_SCHED_CONFIG
Error code: error related to a scheduler configuration.
#define ABTI_CHECK_ERROR(abt_errno)
struct ABT_sched_config_opaque * ABT_sched_config
Scheduler configuration handle type.
ABT_sched_config_var ABT_sched_config_automatic
Predefined ABT_sched_config_var to configure whether the scheduler is freed automatically or not.
int ABT_sched_config_read(ABT_sched_config config, int num_vars,...)
Retrieve values from a scheduler configuration.
static ABT_sched_config ABTI_sched_config_get_handle(ABTI_sched_config *p_config)
ABT_sched_config_var ABT_sched_config_access
Unused predefined ABT_sched_config_var.
#define ABTI_HANDLE_ERROR(n)
static size_t sched_config_type_size(ABT_sched_config_type type)
static ABTU_ret_err int sched_config_add(ABTI_sched_config *p_config, int idx, ABT_sched_config_type type, const void *p_val)
ABT_sched_config_type type
ABT_sched_config_type type
#define ABTI_ASSERT(cond)
int ABT_sched_config_free(ABT_sched_config *config)
Free a scheduler configuration.
@ ABT_SCHED_CONFIG_DOUBLE
static ABTU_ret_err int ABTU_calloc(size_t num, size_t size, void **p_ptr)
#define ABT_SUCCESS
Error code: the routine returns successfully.
#define ABT_SCHED_CONFIG_NULL
ABTI_sched_config_element * p_next
static void sched_config_free(ABTI_sched_config *p_config)
ABTU_ret_err int ABTI_sched_config_read(const ABTI_sched_config *p_config, int idx, void *p_val)
#define ABTI_SCHED_CONFIG_UNUSED_INDEX
static void ABTU_free(void *ptr)
#define ABT_ERR_OTHER
Error code: other error.
ABT_sched_config_var ABT_sched_config_var_end
Predefined ABT_sched_config_var to mark the last parameter.
static ABTI_sched_config * ABTI_sched_config_get_ptr(ABT_sched_config config)
#define ABTI_CHECK_NULL_SCHED_CONFIG_PTR(p)
ABT_sched_config_var ABT_sched_basic_freq
Predefined ABT_sched_config_var to configure the frequency for checking events of the basic scheduler...
static ABTU_noreturn void ABTU_unreachable(void)
int ABT_sched_config_create(ABT_sched_config *config,...)
Create a new scheduler configuration.
ABT_sched_config_type
A struct that sets and gets a scheduler configuration.