ARGOBOTS
Functions
Scheduler config

Functions

int ABT_sched_config_create (ABT_sched_config *config,...)
 Create a scheduler configuration. More...
 
int ABT_sched_config_read (ABT_sched_config config, int num_vars,...)
 Copy the set values from config into the variables passed in the dynamic list of arguments. More...
 
int ABT_sched_config_free (ABT_sched_config *config)
 Free the configuration. More...
 

Detailed Description

This group is for Scheduler config.

Function Documentation

int ABT_sched_config_create ( ABT_sched_config config,
  ... 
)

Create a scheduler configuration.

This function is used to create a specific configuration of a scheduler. The dynamic parameters are a list of tuples composed of the variable of type ABT_sched_config_var and a value for this variable. The list must end with a single value ABT_sched_config_var_end.

For now the parameters can be

  • for all the schedulers
    • ABT_sched_config_access: to choose the access type of the automatically created pools (ABT_POOL_ACCESS_MPSC by default)
    • ABT_sched_config_automatic: to automatically free the scheduler when unused (ABT_TRUE by default)
  • for the basic scheduler:
    • ABT_sched_basic_freq; to set the frequency on checking events

If you want to write your own scheduler and use this function, you can find a good example in the test called sched_config.

For example, if you want to configure the basic scheduler to have a frequency for checking events equal to 5, you will have this call: ABT_sched_config_create(&config, ABT_sched_basic_freq, 5, ABT_sched_config_var_end);

Parameters
[out]configconfiguration to create
[in]...list of arguments
Returns
Error code
Return values
ABT_SUCCESSon success

Definition at line 59 of file config.c.

int ABT_sched_config_free ( ABT_sched_config config)

Free the configuration.

Parameters
[in,out]configconfiguration to free
Returns
Error code
Return values
ABT_SUCCESSon success

Definition at line 197 of file config.c.

int ABT_sched_config_read ( ABT_sched_config  config,
int  num_vars,
  ... 
)

Copy the set values from config into the variables passed in the dynamic list of arguments.

The arguments in ... are the addresses of the variables where to copy the packed data. The packed data are copied to their corresponding variables. For a good example, see the test sched_config.

Parameters
[in]configconfiguration to read
[in]num_varsnumber of variable addresses in ...
[in]...list of arguments
Returns
Error code
Return values
ABT_SUCCESSon success

Definition at line 162 of file config.c.