Go to the documentation of this file.
52 #ifndef ABT_CONFIG_ENABLE_VER_20_API
161 ABTI_CHECK_TRUE(stackaddr == NULL || ((uintptr_t)stackaddr & 0x7) == 0,
309 #ifndef ABT_CONFIG_DISABLE_MIGRATION
314 p_attr->
f_cb = cb_func;
351 #ifndef ABT_CONFIG_DISABLE_MIGRATION
369 if (p_attr == NULL) {
370 fprintf(p_os,
"%*sULT attr: [NULL ATTR]\n", indent,
"");
372 const char *stacktype;
374 stacktype =
"MEMPOOL_DESC";
376 stacktype =
"MALLOC_DESC";
379 stacktype =
"MEMPOOL_DESC_STACK";
382 stacktype =
"MALLOC_DESC_STACK";
384 stacktype =
"UNKNOWN";
386 #ifndef ABT_CONFIG_DISABLE_MIGRATION
419 *pp_dup_attr = p_dup_attr;
433 if (stackaddr != NULL) {
int ABT_bool
Boolean type.
struct ABT_thread_attr_opaque * ABT_thread_attr
ULT attribute handle type.
struct ABT_thread_opaque * ABT_thread
Work unit handle type.
#define ABTI_SETUP_GLOBAL(pp_global)
#define ABTI_THREAD_TYPE_MEM_MEMPOOL_DESC
#define ABTI_CHECK_ERROR(abt_errno)
static ABT_thread_attr ABTI_thread_attr_get_handle(ABTI_thread_attr *p_attr)
int ABT_thread_attr_create(ABT_thread_attr *newattr)
Create a new ULT attribute.
#define ABTI_THREAD_TYPE_MEM_MEMPOOL_DESC_STACK
int ABT_thread_attr_set_stack(ABT_thread_attr attr, void *stackaddr, size_t stacksize)
Set stack attributes in a ULT attribute.
static ABTI_thread_attr * ABTI_thread_attr_get_ptr(ABT_thread_attr attr)
int ABT_thread_attr_free(ABT_thread_attr *attr)
Free a ULT attribute.
#define ABTI_CHECK_NULL_THREAD_ATTR_PTR(p)
ABTU_ret_err int ABTI_thread_attr_dup(const ABTI_thread_attr *p_attr, ABTI_thread_attr **pp_dup_attr)
#define ABTI_HANDLE_ERROR(n)
static ABTU_ret_err int ABTU_malloc(size_t size, void **p_ptr)
static void ABTI_thread_attr_init(ABTI_thread_attr *p_attr, void *p_stack, size_t stacksize, ABTI_thread_type thread_type, ABT_bool migratable)
int ABT_thread_attr_set_migratable(ABT_thread_attr attr, ABT_bool is_migratable)
Set the ULT's migratability in a ULT attribute.
#define ABTI_ASSERT(cond)
#define ABT_THREAD_ATTR_NULL
int ABT_thread_attr_set_callback(ABT_thread_attr attr, void(*cb_func)(ABT_thread thread, void *cb_arg), void *cb_arg)
Set a callback function and its argument in a ULT attribute.
#define ABT_SUCCESS
Error code: the routine returns successfully.
int ABT_thread_attr_get_stacksize(ABT_thread_attr attr, size_t *stacksize)
Get the stack size from a ULT attribute.
#define ABTI_THREAD_TYPES_MEM
uint32_t ABTI_thread_type
#define ABT_TRUE
True constant for ABT_bool.
#define ABT_ERR_INV_ARG
Error code: invalid user argument.
static void ABTU_free(void *ptr)
ABTI_thread_type thread_type
void(* f_cb)(ABT_thread, void *)
int ABT_thread_attr_get_stack(ABT_thread_attr attr, void **stackaddr, size_t *stacksize)
Get stack attributes from a ULT attribute.
#define ABTI_CHECK_TRUE(cond, abt_errno)
#define ABT_ERR_FEATURE_NA
Error code: unsupported feature.
int ABT_thread_attr_set_stacksize(ABT_thread_attr attr, size_t stacksize)
Set stack size in a ULT attribute.
void ABTI_thread_attr_print(ABTI_thread_attr *p_attr, FILE *p_os, int indent)
static void thread_attr_set_stack(ABTI_global *p_global, ABTI_thread_attr *p_attr, void *stackaddr, size_t stacksize)
#define ABTI_THREAD_TYPE_MEM_MALLOC_DESC_STACK
#define ABTI_THREAD_TYPE_MEM_MALLOC_DESC