LLVM OpenMP 20.0.0git
|
#include "kmp.h"
#include "kmp_affinity.h"
#include "kmp_i18n.h"
#include "kmp_io.h"
#include "kmp_itt.h"
#include "kmp_lock.h"
#include "kmp_stats.h"
#include "kmp_str.h"
#include "kmp_wait_release.h"
#include "kmp_wrapper_getpid.h"
#include <alloca.h>
#include <math.h>
#include <sys/resource.h>
#include <sys/syscall.h>
#include <sys/time.h>
#include <sys/times.h>
#include <unistd.h>
#include <ctype.h>
#include <dirent.h>
#include <fcntl.h>
Go to the source code of this file.
Classes | |
struct | kmp_sys_timer |
Macros | |
#define | TIMEVAL_TO_TIMESPEC(tv, ts) |
#define | TS2NS(timespec) (((timespec).tv_sec * (long int)1e9) + (timespec).tv_nsec) |
Typedefs | |
typedef void(* | microtask_t0) (int *, int *) |
typedef void(* | microtask_t1) (int *, int *, void *) |
typedef void(* | microtask_t2) (int *, int *, void *, void *) |
typedef void(* | microtask_t3) (int *, int *, void *, void *, void *) |
typedef void(* | microtask_t4) (int *, int *, void *, void *, void *, void *) |
typedef void(* | microtask_t5) (int *, int *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t6) (int *, int *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t7) (int *, int *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t8) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t9) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t10) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t11) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t12) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t13) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t14) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
typedef void(* | microtask_t15) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Variables | |
static struct kmp_sys_timer | __kmp_sys_timer_data |
static int | __kmp_init_runtime = FALSE |
static int | __kmp_fork_count = 0 |
static pthread_condattr_t | __kmp_suspend_cond_attr |
static pthread_mutexattr_t | __kmp_suspend_mutex_attr |
static kmp_cond_align_t | __kmp_wait_cv |
static kmp_mutex_align_t | __kmp_wait_mx |
kmp_uint64 | __kmp_ticks_per_msec = 1000000 |
kmp_uint64 | __kmp_ticks_per_usec = 1000 |
#define TIMEVAL_TO_TIMESPEC | ( | tv, | |
ts | |||
) |
Definition at line 94 of file z_Linux_util.cpp.
#define TS2NS | ( | timespec | ) | (((timespec).tv_sec * (long int)1e9) + (timespec).tv_nsec) |
Definition at line 102 of file z_Linux_util.cpp.
Definition at line 2754 of file z_Linux_util.cpp.
Definition at line 2755 of file z_Linux_util.cpp.
typedef void(* microtask_t10) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2769 of file z_Linux_util.cpp.
typedef void(* microtask_t11) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2771 of file z_Linux_util.cpp.
typedef void(* microtask_t12) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2774 of file z_Linux_util.cpp.
typedef void(* microtask_t13) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2777 of file z_Linux_util.cpp.
typedef void(* microtask_t14) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2780 of file z_Linux_util.cpp.
typedef void(* microtask_t15) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2783 of file z_Linux_util.cpp.
Definition at line 2756 of file z_Linux_util.cpp.
Definition at line 2757 of file z_Linux_util.cpp.
Definition at line 2758 of file z_Linux_util.cpp.
Definition at line 2759 of file z_Linux_util.cpp.
Definition at line 2761 of file z_Linux_util.cpp.
Definition at line 2763 of file z_Linux_util.cpp.
typedef void(* microtask_t8) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2765 of file z_Linux_util.cpp.
typedef void(* microtask_t9) (int *, int *, void *, void *, void *, void *, void *, void *, void *, void *, void *) |
Definition at line 2767 of file z_Linux_util.cpp.
Definition at line 1305 of file z_Linux_util.cpp.
References __kmp_all_nth, __kmp_console_lock, __kmp_fork_count, __kmp_forkjoin_lock, __kmp_init_bootstrap_lock(), __kmp_init_common, __kmp_init_gtid, __kmp_init_middle, __kmp_init_parallel, __kmp_init_runtime, __kmp_init_serial, __kmp_init_user_locks, __kmp_initz_lock, __kmp_lock_blocks, __kmp_need_register_serial, __kmp_nested_proc_bind, __kmp_nth, __kmp_release_bootstrap_lock(), __kmp_serial_initialize(), __kmp_stdio_lock, __kmp_task_team_lock, __kmp_team_pool, __kmp_thread_pool, __kmp_thread_pool_insert_pt, __kmp_threadpriv_cache_list, __kmp_topology, __kmp_user_lock_table, kmp_cached_addr::addr, kmp_lock_table::allocated, kmp_nested_proc_bind_t::bind_types, FALSE, KA_TRACE, KC_TRACE, kmp_cached_addr::next, proc_bind_false, kmp_lock_table::table, TCW_4, and kmp_lock_table::used.
Referenced by __kmp_register_atfork().
Definition at line 1297 of file z_Linux_util.cpp.
References __kmp_forkjoin_lock, __kmp_initz_lock, and __kmp_release_bootstrap_lock().
Referenced by __kmp_register_atfork().
Definition at line 1292 of file z_Linux_util.cpp.
References __kmp_acquire_bootstrap_lock(), __kmp_forkjoin_lock, and __kmp_initz_lock.
Referenced by __kmp_register_atfork().
void __kmp_atomic_resume_64 | ( | int | target_gtid, |
kmp_atomic_flag_64< C, S > * | flag | ||
) |
Definition at line 1760 of file z_Linux_util.cpp.
template void __kmp_atomic_resume_64< false, true > | ( | int | , |
kmp_atomic_flag_64< false, true > * | |||
) |
void __kmp_atomic_suspend_64 | ( | int | th_gtid, |
kmp_atomic_flag_64< C, S > * | flag | ||
) |
Definition at line 1654 of file z_Linux_util.cpp.
template void __kmp_atomic_suspend_64< false, true > | ( | int | , |
kmp_atomic_flag_64< false, true > * | |||
) |
template void __kmp_atomic_suspend_64< true, false > | ( | int | , |
kmp_atomic_flag_64< true, false > * | |||
) |
Definition at line 1888 of file z_Linux_util.cpp.
void __kmp_create_worker | ( | int | gtid, |
kmp_info_t * | th, | ||
size_t | stack_size | ||
) |
Definition at line 780 of file z_Linux_util.cpp.
bool __kmp_detect_shm | ( | ) |
Definition at line 3083 of file z_Linux_util.cpp.
Referenced by __kmp_register_library_startup().
bool __kmp_detect_tmp | ( | ) |
Definition at line 3095 of file z_Linux_util.cpp.
Referenced by __kmp_register_library_startup().
Definition at line 1284 of file z_Linux_util.cpp.
void __kmp_do_initialize_hidden_helper_threads | ( | ) |
Definition at line 3050 of file z_Linux_util.cpp.
Definition at line 2055 of file z_Linux_util.cpp.
Definition at line 2075 of file z_Linux_util.cpp.
Definition at line 1275 of file z_Linux_util.cpp.
Definition at line 1058 of file z_Linux_util.cpp.
Definition at line 1896 of file z_Linux_util.cpp.
References __kmp_type_convert(), and r.
Referenced by __kmp_runtime_initialize().
Definition at line 1816 of file z_Linux_util.cpp.
Definition at line 1805 of file z_Linux_util.cpp.
Referenced by __kmp_launch_worker().
void __kmp_hidden_helper_initz_release | ( | ) |
Definition at line 3058 of file z_Linux_util.cpp.
void __kmp_hidden_helper_main_thread_release | ( | ) |
Definition at line 3066 of file z_Linux_util.cpp.
void __kmp_hidden_helper_main_thread_wait | ( | ) |
Definition at line 3062 of file z_Linux_util.cpp.
void __kmp_hidden_helper_threads_deinitz_release | ( | ) |
Definition at line 3078 of file z_Linux_util.cpp.
void __kmp_hidden_helper_threads_deinitz_wait | ( | ) |
Definition at line 3074 of file z_Linux_util.cpp.
void __kmp_hidden_helper_threads_initz_wait | ( | ) |
Definition at line 3054 of file z_Linux_util.cpp.
void __kmp_hidden_helper_worker_thread_signal | ( | ) |
Definition at line 3070 of file z_Linux_util.cpp.
void __kmp_hidden_helper_worker_thread_wait | ( | ) |
Definition at line 3046 of file z_Linux_util.cpp.
Definition at line 2789 of file z_Linux_util.cpp.
References OMPT_GET_FRAME_ADDRESS.
Referenced by __kmp_fork_in_teams(), __kmp_invoke_task_func(), __kmp_serial_fork_call(), and __kmpc_fork_call_if().
Definition at line 2110 of file z_Linux_util.cpp.
Definition at line 528 of file z_Linux_util.cpp.
References __kmp_check_stack_overlap(), __kmp_gtid_set_specific(), __kmp_launch_thread(), __kmp_set_stack_info(), __kmp_stkoffset, KMP_ALLOCA, KMP_CHECK_SYSFAIL, KMP_CHECK_SYSFAIL_ERRNO, KMP_INIT_PARTITIONED_TIMERS, KMP_MB, KMP_SET_THREAD_STATE, status, and void.
Referenced by __kmp_create_worker().
void __kmp_lock_suspend_mx | ( | kmp_info_t * | th | ) |
Definition at line 1474 of file z_Linux_util.cpp.
Referenced by __kmp_resume_template(), and __kmp_suspend_template().
kmp_uint64 __kmp_now_nsec | ( | ) |
Definition at line 2078 of file z_Linux_util.cpp.
Definition at line 1834 of file z_Linux_util.cpp.
int __kmp_read_system_info | ( | struct kmp_sys_info * | info | ) |
Definition at line 1844 of file z_Linux_util.cpp.
Definition at line 1875 of file z_Linux_util.cpp.
void __kmp_reap_monitor | ( | kmp_info_t * | th | ) |
Definition at line 1114 of file z_Linux_util.cpp.
References void.
Referenced by __kmp_internal_end().
void __kmp_reap_worker | ( | kmp_info_t * | th | ) |
Definition at line 1117 of file z_Linux_util.cpp.
Definition at line 1405 of file z_Linux_util.cpp.
References __kmp_atfork_child(), __kmp_atfork_parent(), __kmp_atfork_prepare(), __kmp_need_register_atfork, FALSE, KMP_CHECK_SYSFAIL, and status.
Referenced by __kmp_do_serial_initialize().
Definition at line 1752 of file z_Linux_util.cpp.
template void __kmp_resume_32< false, false > | ( | int | , |
kmp_flag_32< false, false > * | |||
) |
template void __kmp_resume_32< false, true > | ( | int | , |
kmp_flag_32< false, true > * | |||
) |
Definition at line 1756 of file z_Linux_util.cpp.
template void __kmp_resume_64< false, true > | ( | int | , |
kmp_flag_64< false, true > * | |||
) |
void __kmp_resume_oncore | ( | int | target_gtid, |
kmp_flag_oncore * | flag | ||
) |
Definition at line 1763 of file z_Linux_util.cpp.
Definition at line 1673 of file z_Linux_util.cpp.
References __kmp_get_gtid, __kmp_init_gtid, __kmp_lock_suspend_mx(), __kmp_null_resume_wrapper(), __kmp_printf(), __kmp_suspend_initialize_thread(), __kmp_threads, __kmp_unlock_suspend_mx(), C, CCAST, flag, flag_unset, KF_TRACE, KMP_CHECK_SYSFAIL, KMP_DEBUG_ASSERT, KMP_TIME_DEVELOPER_PARTITIONED_BLOCK, status, TCR_4, and TCW_PTR.
Referenced by __kmp_atomic_resume_64(), __kmp_resume_32(), __kmp_resume_64(), and __kmp_resume_oncore().
Definition at line 2021 of file z_Linux_util.cpp.
Definition at line 1941 of file z_Linux_util.cpp.
|
static |
Definition at line 465 of file z_Linux_util.cpp.
References addr, FALSE, KA_TRACE, KMP_CHECK_SYSFAIL, KMP_UBER_GTID(), s, size, status, TCW_4, TCW_PTR, and TRUE.
Referenced by __kmp_create_worker(), and __kmp_launch_worker().
Definition at line 1646 of file z_Linux_util.cpp.
template void __kmp_suspend_32< false, false > | ( | int | , |
kmp_flag_32< false, false > * | |||
) |
Definition at line 1650 of file z_Linux_util.cpp.
template void __kmp_suspend_64< false, true > | ( | int | , |
kmp_flag_64< false, true > * | |||
) |
template void __kmp_suspend_64< true, false > | ( | int | , |
kmp_flag_64< true, false > * | |||
) |
Definition at line 1416 of file z_Linux_util.cpp.
void __kmp_suspend_initialize_thread | ( | kmp_info_t * | th | ) |
Definition at line 1424 of file z_Linux_util.cpp.
Referenced by __kmp_resume_template(), and __kmp_suspend_template().
void __kmp_suspend_oncore | ( | int | th_gtid, |
kmp_flag_oncore * | flag | ||
) |
Definition at line 1657 of file z_Linux_util.cpp.
Definition at line 1487 of file z_Linux_util.cpp.
References __kmp_dflt_blocktime, __kmp_lock_suspend_mx(), __kmp_pause_status, __kmp_printf(), __kmp_suspend_initialize_thread(), __kmp_thread_pool_active_nth, __kmp_threads, __kmp_unlock_suspend_mx(), FALSE, flag, flag_unset, KF_TRACE, KMP_ATOMIC_DEC, KMP_ATOMIC_INC, KMP_CHECK_SYSFAIL_ERRNO, KMP_DEBUG_ASSERT, KMP_MAX_BLOCKTIME, kmp_soft_paused, KMP_SYSFAIL, KMP_TIME_DEVELOPER_PARTITIONED_BLOCK, status, TCR_4, TCW_PTR, TIMEVAL_TO_TIMESPEC, and TRUE.
Referenced by __kmp_atomic_suspend_64(), __kmp_suspend_32(), __kmp_suspend_64(), and __kmp_suspend_oncore().
void __kmp_suspend_uninitialize_thread | ( | kmp_info_t * | th | ) |
Definition at line 1449 of file z_Linux_util.cpp.
Definition at line 443 of file z_Linux_util.cpp.
Definition at line 2052 of file z_Linux_util.cpp.
int __kmp_try_suspend_mx | ( | kmp_info_t * | th | ) |
Definition at line 1470 of file z_Linux_util.cpp.
void __kmp_unlock_suspend_mx | ( | kmp_info_t * | th | ) |
Definition at line 1479 of file z_Linux_util.cpp.
Referenced by __kmp_resume_template(), and __kmp_suspend_template().
void __kmp_yield | ( | ) |
Definition at line 1803 of file z_Linux_util.cpp.
|
static |
Definition at line 115 of file z_Linux_util.cpp.
Referenced by __kmp_atfork_child(), __kmp_suspend_initialize_thread(), and __kmp_suspend_uninitialize_thread().
Definition at line 113 of file z_Linux_util.cpp.
Referenced by __kmp_atfork_child(), __kmp_runtime_destroy(), and __kmp_runtime_initialize().
|
static |
Definition at line 117 of file z_Linux_util.cpp.
Referenced by __kmp_suspend_initialize(), and __kmp_suspend_initialize_thread().
|
static |
Definition at line 118 of file z_Linux_util.cpp.
Referenced by __kmp_suspend_initialize(), and __kmp_suspend_initialize_thread().
|
static |
Definition at line 105 of file z_Linux_util.cpp.
Referenced by __kmp_clear_system_time(), and __kmp_read_system_time().
kmp_uint64 __kmp_ticks_per_msec = 1000000 |
Definition at line 123 of file z_Linux_util.cpp.
kmp_uint64 __kmp_ticks_per_usec = 1000 |
Definition at line 124 of file z_Linux_util.cpp.
|
static |
Definition at line 120 of file z_Linux_util.cpp.
Referenced by __kmp_runtime_destroy(), and __kmp_runtime_initialize().
|
static |
Definition at line 121 of file z_Linux_util.cpp.
Referenced by __kmp_runtime_destroy(), and __kmp_runtime_initialize().