ARGOBOTS  1.1
Functions
stream.c File Reference
#include "abti.h"
Include dependency graph for stream.c:

Go to the source code of this file.

Functions

static ABTU_ret_err int xstream_create (ABTI_global *p_global, ABTI_sched *p_sched, ABTI_xstream_type xstream_type, int rank, ABT_bool start, ABTI_xstream **pp_xstream)
 
static ABTU_ret_err int xstream_join (ABTI_local **pp_local, ABTI_xstream *p_xstream)
 
static ABT_bool xstream_set_new_rank (ABTI_global *p_global, ABTI_xstream *p_newxstream, int rank)
 
static ABT_bool xstream_change_rank (ABTI_global *p_global, ABTI_xstream *p_xstream, int rank)
 
static void xstream_return_rank (ABTI_global *p_global, ABTI_xstream *p_xstream)
 
static void xstream_schedule_ythread (ABTI_global *p_global, ABTI_xstream **pp_local_xstream, ABTI_ythread *p_ythread)
 
static void xstream_schedule_task (ABTI_global *p_global, ABTI_xstream *p_local_xstream, ABTI_thread *p_task)
 
static void xstream_init_main_sched (ABTI_xstream *p_xstream, ABTI_sched *p_sched)
 
static ABTU_ret_err int xstream_update_main_sched (ABTI_global *p_global, ABTI_xstream **pp_local_xstream, ABTI_xstream *p_xstream, ABTI_sched *p_sched)
 
static void * xstream_launch_root_ythread (void *p_xstream)
 
static ABTU_ret_err int xstream_migrate_thread (ABTI_global *p_global, ABTI_local *p_local, ABTI_thread *p_thread)
 
int ABT_xstream_create (ABT_sched sched, ABT_xstream *newxstream)
 Create a new execution stream. More...
 
int ABT_xstream_create_basic (ABT_sched_predef predef, int num_pools, ABT_pool *pools, ABT_sched_config config, ABT_xstream *newxstream)
 Create a new execution stream with a predefined scheduler. More...
 
int ABT_xstream_create_with_rank (ABT_sched sched, int rank, ABT_xstream *newxstream)
 Create a new execution stream with a specific rank. More...
 
int ABT_xstream_revive (ABT_xstream xstream)
 Revive a terminated execution stream. More...
 
int ABT_xstream_free (ABT_xstream *xstream)
 Free an execution stream. More...
 
int ABT_xstream_join (ABT_xstream xstream)
 Wait for an execution stream to terminate. More...
 
int ABT_xstream_exit (void)
 Terminate an execution stream that is running the calling ULT. More...
 
int ABT_xstream_cancel (ABT_xstream xstream)
 Send a cancellation request to an execution stream. More...
 
int ABT_xstream_self (ABT_xstream *xstream)
 Get an execution stream that is running the calling work unit. More...
 
int ABT_xstream_self_rank (int *rank)
 Return a rank of an execution stream associated with a caller. More...
 
int ABT_xstream_set_rank (ABT_xstream xstream, int rank)
 Set a rank for an execution stream. More...
 
int ABT_xstream_get_rank (ABT_xstream xstream, int *rank)
 Retrieve a rank of an execution stream. More...
 
int ABT_xstream_set_main_sched (ABT_xstream xstream, ABT_sched sched)
 Set the main scheduler of an execution stream. More...
 
int ABT_xstream_set_main_sched_basic (ABT_xstream xstream, ABT_sched_predef predef, int num_pools, ABT_pool *pools)
 Set the main scheduler of an execution stream to a predefined scheduler. More...
 
int ABT_xstream_get_main_sched (ABT_xstream xstream, ABT_sched *sched)
 Retrieve the main scheduler of an execution stream. More...
 
int ABT_xstream_get_main_pools (ABT_xstream xstream, int max_pools, ABT_pool *pools)
 Get pools associated with the main scheduler of an execution stream. More...
 
int ABT_xstream_get_state (ABT_xstream xstream, ABT_xstream_state *state)
 Get a state of an execution stream. More...
 
int ABT_xstream_equal (ABT_xstream xstream1, ABT_xstream xstream2, ABT_bool *result)
 Compare two execution stream handles for equality. More...
 
int ABT_xstream_get_num (int *num_xstreams)
 Get the number of current existing execution streams. More...
 
int ABT_xstream_is_primary (ABT_xstream xstream, ABT_bool *is_primary)
 Check if the target execution stream is primary. More...
 
int ABT_xstream_run_unit (ABT_unit unit, ABT_pool pool)
 Execute a work unit. More...
 
int ABT_xstream_check_events (ABT_sched sched)
 Process events associated with a scheduler. More...
 
int ABT_xstream_set_cpubind (ABT_xstream xstream, int cpuid)
 Bind an execution stream to a target CPU. More...
 
int ABT_xstream_get_cpubind (ABT_xstream xstream, int *cpuid)
 Get CPU ID of a CPU to which an execution stream is bound. More...
 
int ABT_xstream_set_affinity (ABT_xstream xstream, int num_cpuids, int *cpuids)
 Bind an execution stream to target CPUs. More...
 
int ABT_xstream_get_affinity (ABT_xstream xstream, int max_cpuids, int *cpuids, int *num_cpuids)
 Get CPU IDs of CPUs to which an execution stream is bound. More...
 
ABTU_ret_err int ABTI_xstream_create_primary (ABTI_global *p_global, ABTI_xstream **pp_xstream)
 
void ABTI_xstream_start_primary (ABTI_global *p_global, ABTI_xstream **pp_local_xstream, ABTI_xstream *p_xstream, ABTI_ythread *p_ythread)
 
void ABTI_xstream_run_thread (ABTI_global *p_global, ABTI_xstream **pp_local_xstream, ABTI_thread *p_thread)
 
void ABTI_xstream_check_events (ABTI_xstream *p_xstream, ABTI_sched *p_sched)
 
void ABTI_xstream_free (ABTI_global *p_global, ABTI_local *p_local, ABTI_xstream *p_xstream, ABT_bool force_free)
 
void ABTI_xstream_print (ABTI_xstream *p_xstream, FILE *p_os, int indent, ABT_bool print_sub)
 
static void xstream_update_max_xstreams (ABTI_global *p_global, int newrank)
 
static void xstream_add_xstream_list (ABTI_global *p_global, ABTI_xstream *p_newxstream)
 
static void xstream_remove_xstream_list (ABTI_global *p_global, ABTI_xstream *p_xstream)
 

Function Documentation

◆ ABTI_xstream_check_events()

void ABTI_xstream_check_events ( ABTI_xstream p_xstream,
ABTI_sched p_sched 
)

Definition at line 1568 of file stream.c.

Referenced by sched_run().

◆ ABTI_xstream_create_primary()

ABTU_ret_err int ABTI_xstream_create_primary ( ABTI_global p_global,
ABTI_xstream **  pp_xstream 
)

Definition at line 1500 of file stream.c.

Referenced by init_library().

◆ ABTI_xstream_free()

void ABTI_xstream_free ( ABTI_global p_global,
ABTI_local p_local,
ABTI_xstream p_xstream,
ABT_bool  force_free 
)

Definition at line 1584 of file stream.c.

Referenced by ABT_xstream_free(), finailze_library(), and init_library().

◆ ABTI_xstream_print()

void ABTI_xstream_print ( ABTI_xstream p_xstream,
FILE *  p_os,
int  indent,
ABT_bool  print_sub 
)

Definition at line 1620 of file stream.c.

Referenced by ABT_info_print_all_xstreams(), and ABT_info_print_xstream().

◆ ABTI_xstream_run_thread()

void ABTI_xstream_run_thread ( ABTI_global p_global,
ABTI_xstream **  pp_local_xstream,
ABTI_thread p_thread 
)

Definition at line 1554 of file stream.c.

Referenced by sched_run().

◆ ABTI_xstream_start_primary()

void ABTI_xstream_start_primary ( ABTI_global p_global,
ABTI_xstream **  pp_local_xstream,
ABTI_xstream p_xstream,
ABTI_ythread p_ythread 
)

Definition at line 1525 of file stream.c.

Referenced by init_library().

◆ xstream_add_xstream_list()

static void xstream_add_xstream_list ( ABTI_global p_global,
ABTI_xstream p_newxstream 
)
static

Definition at line 2173 of file stream.c.

◆ xstream_change_rank()

static ABT_bool xstream_change_rank ( ABTI_global p_global,
ABTI_xstream p_xstream,
int  rank 
)
static

Definition at line 2276 of file stream.c.

Referenced by ABT_xstream_set_rank().

◆ xstream_create()

static ABTU_ret_err int xstream_create ( ABTI_global p_global,
ABTI_sched p_sched,
ABTI_xstream_type  xstream_type,
int  rank,
ABT_bool  start,
ABTI_xstream **  pp_xstream 
)
static

◆ xstream_init_main_sched()

static void xstream_init_main_sched ( ABTI_xstream p_xstream,
ABTI_sched p_sched 
)
static

Definition at line 2039 of file stream.c.

Referenced by xstream_create().

◆ xstream_join()

static ABTU_ret_err int xstream_join ( ABTI_local **  pp_local,
ABTI_xstream p_xstream 
)
static

Definition at line 1809 of file stream.c.

Referenced by ABT_xstream_free(), and ABT_xstream_join().

◆ xstream_launch_root_ythread()

static void * xstream_launch_root_ythread ( void *  p_xstream)
static

Definition at line 1676 of file stream.c.

Referenced by xstream_create().

◆ xstream_migrate_thread()

static ABTU_ret_err int xstream_migrate_thread ( ABTI_global p_global,
ABTI_local p_local,
ABTI_thread p_thread 
)
static

Definition at line 1998 of file stream.c.

◆ xstream_remove_xstream_list()

static void xstream_remove_xstream_list ( ABTI_global p_global,
ABTI_xstream p_xstream 
)
static

Definition at line 2219 of file stream.c.

◆ xstream_return_rank()

static void xstream_return_rank ( ABTI_global p_global,
ABTI_xstream p_xstream 
)
static

Definition at line 2308 of file stream.c.

Referenced by xstream_create().

◆ xstream_schedule_task()

static void xstream_schedule_task ( ABTI_global p_global,
ABTI_xstream p_local_xstream,
ABTI_thread p_task 
)
inlinestatic

Definition at line 1949 of file stream.c.

◆ xstream_schedule_ythread()

static void xstream_schedule_ythread ( ABTI_global p_global,
ABTI_xstream **  pp_local_xstream,
ABTI_ythread p_ythread 
)
inlinestatic

Definition at line 1833 of file stream.c.

◆ xstream_set_new_rank()

static ABT_bool xstream_set_new_rank ( ABTI_global p_global,
ABTI_xstream p_newxstream,
int  rank 
)
static

Definition at line 2234 of file stream.c.

Referenced by xstream_create().

◆ xstream_update_main_sched()

static int xstream_update_main_sched ( ABTI_global p_global,
ABTI_xstream **  pp_local_xstream,
ABTI_xstream p_xstream,
ABTI_sched p_sched 
)
static

Definition at line 2049 of file stream.c.

Referenced by ABT_xstream_set_main_sched_basic().

◆ xstream_update_max_xstreams()

static void xstream_update_max_xstreams ( ABTI_global p_global,
int  newrank 
)
static

Definition at line 2141 of file stream.c.