ARGOBOTS  dce6e727ffc4ca5b3ffc04cb9517c6689be51ec5
Data Structures | Typedefs | Functions
unit.c File Reference
#include "abti.h"
Include dependency graph for unit.c:

Go to the source code of this file.

Data Structures

struct  atomic_unit
 
struct  unit_to_thread
 

Typedefs

typedef struct atomic_unit atomic_unit
 
typedef struct unit_to_thread unit_to_thread
 

Functions

static void unit_init_hash_table (ABTI_global *p_global)
 
static void unit_finalize_hash_table (ABTI_global *p_global)
 
static ABTU_ret_err int unit_map_thread (ABTI_global *p_global, ABT_unit unit, ABTI_thread *p_thread)
 
static void unit_unmap_thread (ABTI_global *p_global, ABT_unit unit)
 
static ABTI_threadunit_get_thread_from_user_defined_unit (ABTI_global *p_global, ABT_unit unit)
 
int ABT_unit_set_associated_pool (ABT_unit unit, ABT_pool pool)
 No operation. More...
 
int ABT_unit_get_thread (ABT_unit unit, ABT_thread *thread)
 Get a thread handle of the target work unit. More...
 
void ABTI_unit_init_hash_table (ABTI_global *p_global)
 
void ABTI_unit_finalize_hash_table (ABTI_global *p_global)
 
ABTU_ret_err int ABTI_unit_map_thread (ABTI_global *p_global, ABT_unit unit, ABTI_thread *p_thread)
 
void ABTI_unit_unmap_thread (ABTI_global *p_global, ABT_unit unit)
 
ABTI_threadABTI_unit_get_thread_from_user_defined_unit (ABTI_global *p_global, ABT_unit unit)
 
static size_t unit_get_hash_index (ABT_unit unit)
 
static ABT_unit atomic_relaxed_load_unit (const atomic_unit *p_ptr)
 
static void atomic_relaxed_store_unit (atomic_unit *p_ptr, ABT_unit val)
 
static unit_to_threadatomic_acquire_load_unit_to_thread (const ABTI_atomic_unit_to_thread *p_ptr)
 
static unit_to_threadatomic_relaxed_load_unit_to_thread (const ABTI_atomic_unit_to_thread *p_ptr)
 
static void atomic_release_store_unit_to_thread (ABTI_atomic_unit_to_thread *p_ptr, unit_to_thread *val)
 
static void atomic_relaxed_store_unit_to_thread (ABTI_atomic_unit_to_thread *p_ptr, unit_to_thread *val)
 

Typedef Documentation

◆ atomic_unit

typedef struct atomic_unit atomic_unit

◆ unit_to_thread

Function Documentation

◆ ABTI_unit_finalize_hash_table()

void ABTI_unit_finalize_hash_table ( ABTI_global p_global)

Definition at line 101 of file unit.c.

Referenced by finailze_library().

◆ ABTI_unit_get_thread_from_user_defined_unit()

ABTI_thread* ABTI_unit_get_thread_from_user_defined_unit ( ABTI_global p_global,
ABT_unit  unit 
)

Definition at line 117 of file unit.c.

Referenced by ABTI_unit_get_thread(), and ABTI_unit_set_associated_pool().

◆ ABTI_unit_init_hash_table()

void ABTI_unit_init_hash_table ( ABTI_global p_global)

Definition at line 96 of file unit.c.

Referenced by init_library().

◆ ABTI_unit_map_thread()

ABTU_ret_err int ABTI_unit_map_thread ( ABTI_global p_global,
ABT_unit  unit,
ABTI_thread p_thread 
)

◆ ABTI_unit_unmap_thread()

void ABTI_unit_unmap_thread ( ABTI_global p_global,
ABT_unit  unit 
)

◆ atomic_acquire_load_unit_to_thread()

static unit_to_thread* atomic_acquire_load_unit_to_thread ( const ABTI_atomic_unit_to_thread p_ptr)
inlinestatic

Definition at line 168 of file unit.c.

Referenced by unit_get_thread_from_user_defined_unit().

◆ atomic_relaxed_load_unit()

static ABT_unit atomic_relaxed_load_unit ( const atomic_unit p_ptr)
inlinestatic

◆ atomic_relaxed_load_unit_to_thread()

static unit_to_thread* atomic_relaxed_load_unit_to_thread ( const ABTI_atomic_unit_to_thread p_ptr)
inlinestatic

Definition at line 174 of file unit.c.

Referenced by unit_finalize_hash_table(), unit_map_thread(), and unit_unmap_thread().

◆ atomic_relaxed_store_unit()

static void atomic_relaxed_store_unit ( atomic_unit p_ptr,
ABT_unit  val 
)
inlinestatic

Definition at line 150 of file unit.c.

Referenced by unit_map_thread(), and unit_unmap_thread().

◆ atomic_relaxed_store_unit_to_thread()

static void atomic_relaxed_store_unit_to_thread ( ABTI_atomic_unit_to_thread p_ptr,
unit_to_thread val 
)
inlinestatic

Definition at line 187 of file unit.c.

Referenced by unit_init_hash_table().

◆ atomic_release_store_unit_to_thread()

static void atomic_release_store_unit_to_thread ( ABTI_atomic_unit_to_thread p_ptr,
unit_to_thread val 
)
inlinestatic

Definition at line 180 of file unit.c.

Referenced by unit_map_thread().

◆ unit_finalize_hash_table()

static void unit_finalize_hash_table ( ABTI_global p_global)
static

Definition at line 204 of file unit.c.

Referenced by ABTI_unit_finalize_hash_table().

◆ unit_get_hash_index()

static size_t unit_get_hash_index ( ABT_unit  unit)
inlinestatic

◆ unit_get_thread_from_user_defined_unit()

static ABTI_thread * unit_get_thread_from_user_defined_unit ( ABTI_global p_global,
ABT_unit  unit 
)
inlinestatic

Definition at line 283 of file unit.c.

Referenced by ABTI_unit_get_thread_from_user_defined_unit().

◆ unit_init_hash_table()

static void unit_init_hash_table ( ABTI_global p_global)
static

Definition at line 193 of file unit.c.

Referenced by ABTI_unit_init_hash_table().

◆ unit_map_thread()

static ABTU_ret_err int unit_map_thread ( ABTI_global p_global,
ABT_unit  unit,
ABTI_thread p_thread 
)
inlinestatic

Definition at line 223 of file unit.c.

Referenced by ABTI_unit_map_thread().

◆ unit_unmap_thread()

static void unit_unmap_thread ( ABTI_global p_global,
ABT_unit  unit 
)
inlinestatic

Definition at line 261 of file unit.c.

Referenced by ABTI_unit_unmap_thread().