Lines Matching defs:status
444 int status;
452 status = pthread_cancel(th->th.th_info.ds.ds_thread);
453 if (status != 0 && status != ESRCH) {
454 __kmp_fatal(KMP_MSG(CantTerminateWorkerThread), KMP_ERR(status),
469 int status;
480 if ((status = thr_stksegment(&s)) < 0) {
481 KMP_CHECK_SYSFAIL("thr_stksegment", status);
492 status = pthread_attr_init(&attr);
493 KMP_CHECK_SYSFAIL("pthread_attr_init", status);
495 status = pthread_attr_get_np(pthread_self(), &attr);
496 KMP_CHECK_SYSFAIL("pthread_attr_get_np", status);
498 status = pthread_getattr_np(pthread_self(), &attr);
499 KMP_CHECK_SYSFAIL("pthread_getattr_np", status);
501 status = pthread_attr_getstack(&attr, &addr, &size);
502 KMP_CHECK_SYSFAIL("pthread_attr_getstack", status);
507 status = pthread_attr_destroy(&attr);
508 KMP_CHECK_SYSFAIL("pthread_attr_destroy", status);
529 int status, old_type, old_state;
562 status = pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, &old_type);
563 KMP_CHECK_SYSFAIL("pthread_setcanceltype", status);
565 status = pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, &old_state);
566 KMP_CHECK_SYSFAIL("pthread_setcancelstate", status);
577 status = sigfillset(&new_set);
578 KMP_CHECK_SYSFAIL_ERRNO("sigfillset", status);
579 status = pthread_sigmask(SIG_BLOCK, &new_set, &old_set);
580 KMP_CHECK_SYSFAIL("pthread_sigmask", status);
599 status = pthread_sigmask(SIG_SETMASK, &old_set, NULL);
600 KMP_CHECK_SYSFAIL("pthread_sigmask", status);
610 int status, old_type, old_state;
639 status = pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, &old_type);
640 KMP_CHECK_SYSFAIL("pthread_setcanceltype", status);
642 status = pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, &old_state);
643 KMP_CHECK_SYSFAIL("pthread_setcancelstate", status);
706 status = gettimeofday(&tval, NULL);
707 KMP_CHECK_SYSFAIL_ERRNO("gettimeofday", status);
718 status = pthread_mutex_lock(&__kmp_wait_mx.m_mutex);
719 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
722 status = pthread_cond_timedwait(&__kmp_wait_cv.c_cond,
724 if (status != 0) {
725 if (status != ETIMEDOUT && status != EINTR) {
726 KMP_SYSFAIL("pthread_cond_timedwait", status);
730 status = pthread_mutex_unlock(&__kmp_wait_mx.m_mutex);
731 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
742 status = sigfillset(&new_set);
743 KMP_CHECK_SYSFAIL_ERRNO("sigfillset", status);
744 status = pthread_sigmask(SIG_UNBLOCK, &new_set, NULL);
745 KMP_CHECK_SYSFAIL("pthread_sigmask", status);
783 int status;
819 status = pthread_attr_init(&thread_attr);
820 if (status != 0) {
821 __kmp_fatal(KMP_MSG(CantInitThreadAttrs), KMP_ERR(status), __kmp_msg_null);
823 status = pthread_attr_setdetachstate(&thread_attr, PTHREAD_CREATE_JOINABLE);
824 if (status != 0) {
825 __kmp_fatal(KMP_MSG(CantSetWorkerState), KMP_ERR(status), __kmp_msg_null);
842 status = pthread_attr_setstacksize(&thread_attr, stack_size);
844 if (status != 0) {
852 status = pthread_attr_setstacksize(&thread_attr, stack_size);
856 if (status != 0) {
857 __kmp_fatal(KMP_MSG(CantSetWorkerStackSize, stack_size), KMP_ERR(status),
864 status =
866 if (status != 0 || !handle) { // ??? Why do we check handle??
868 if (status == EINVAL) {
869 __kmp_fatal(KMP_MSG(CantSetWorkerStackSize, stack_size), KMP_ERR(status),
872 if (status == ENOMEM) {
873 __kmp_fatal(KMP_MSG(CantSetWorkerStackSize, stack_size), KMP_ERR(status),
877 if (status == EAGAIN) {
878 __kmp_fatal(KMP_MSG(NoResourcesForWorkerThread), KMP_ERR(status),
881 KMP_SYSFAIL("pthread_create", status);
900 status = pthread_attr_destroy(&thread_attr);
901 if (status) {
902 kmp_msg_t err_code = KMP_ERR(status);
922 int status;
951 status = pthread_attr_init(&thread_attr);
952 if (status != 0) {
953 __kmp_fatal(KMP_MSG(CantInitThreadAttrs), KMP_ERR(status), __kmp_msg_null);
955 status = pthread_attr_setdetachstate(&thread_attr, PTHREAD_CREATE_JOINABLE);
956 if (status != 0) {
957 __kmp_fatal(KMP_MSG(CantSetMonitorState), KMP_ERR(status), __kmp_msg_null);
961 status = pthread_attr_getstacksize(&thread_attr, &size);
962 KMP_CHECK_SYSFAIL("pthread_attr_getstacksize", status);
985 status = pthread_attr_setstacksize(&thread_attr, __kmp_monitor_stksize);
986 if (status != 0) {
991 kmp_msg_t err_code = KMP_ERR(status);
1001 status =
1004 if (status != 0) {
1006 if (status == EINVAL) {
1012 KMP_ERR(status), KMP_HNT(IncreaseMonitorStackSize),
1015 if (status == ENOMEM) {
1017 KMP_ERR(status), KMP_HNT(DecreaseMonitorStackSize),
1021 if (status == EAGAIN) {
1022 __kmp_fatal(KMP_MSG(NoResourcesForMonitorThread), KMP_ERR(status),
1025 KMP_SYSFAIL("pthread_create", status);
1039 status = pthread_attr_destroy(&thread_attr);
1040 if (status != 0) {
1041 kmp_msg_t err_code = KMP_ERR(status);
1070 int status;
1092 status = pthread_kill(th->th.th_info.ds.ds_thread, 0);
1093 if (status != ESRCH) {
1097 status = pthread_join(th->th.th_info.ds.ds_thread, &exit_val);
1099 __kmp_fatal(KMP_MSG(ReapMonitorError), KMP_ERR(status), __kmp_msg_null);
1118 int status;
1126 status = pthread_join(th->th.th_info.ds.ds_thread, &exit_val);
1129 if (status != 0) {
1130 __kmp_fatal(KMP_MSG(ReapWorkerError), KMP_ERR(status), __kmp_msg_null);
1138 (void)status; // unused variable
1277 int status, old_state;
1278 status = pthread_setcancelstate(new_state, &old_state);
1279 KMP_CHECK_SYSFAIL("pthread_setcancelstate", status);
1286 int status;
1287 status = pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, old_state);
1288 KMP_CHECK_SYSFAIL("pthread_setcancelstate", status);
1408 int status = pthread_atfork(__kmp_atfork_prepare, __kmp_atfork_parent,
1410 KMP_CHECK_SYSFAIL("pthread_atfork", status);
1417 int status;
1418 status = pthread_mutexattr_init(&__kmp_suspend_mutex_attr);
1419 KMP_CHECK_SYSFAIL("pthread_mutexattr_init", status);
1420 status = pthread_condattr_init(&__kmp_suspend_cond_attr);
1421 KMP_CHECK_SYSFAIL("pthread_condattr_init", status);
1438 int status;
1439 status = pthread_cond_init(&th->th.th_suspend_cv.c_cond,
1441 KMP_CHECK_SYSFAIL("pthread_cond_init", status);
1442 status = pthread_mutex_init(&th->th.th_suspend_mx.m_mutex,
1444 KMP_CHECK_SYSFAIL("pthread_mutex_init", status);
1453 int status;
1455 status = pthread_cond_destroy(&th->th.th_suspend_cv.c_cond);
1456 if (status != 0 && status != EBUSY) {
1457 KMP_SYSFAIL("pthread_cond_destroy", status);
1459 status = pthread_mutex_destroy(&th->th.th_suspend_mx.m_mutex);
1460 if (status != 0 && status != EBUSY) {
1461 KMP_SYSFAIL("pthread_mutex_destroy", status);
1475 int status = pthread_mutex_lock(&th->th.th_suspend_mx.m_mutex);
1476 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
1480 int status = pthread_mutex_unlock(&th->th.th_suspend_mx.m_mutex);
1481 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
1490 int status;
1561 status = gettimeofday(&tval, NULL);
1562 KMP_CHECK_SYSFAIL_ERRNO("gettimeofday", status);
1572 status = pthread_cond_timedwait(&th->th.th_suspend_cv.c_cond,
1578 status = pthread_cond_wait(&th->th.th_suspend_cv.c_cond,
1582 if ((status != 0) && (status != EINTR) && (status != ETIMEDOUT)) {
1583 KMP_SYSFAIL("pthread_cond_wait", status);
1589 ((status == EINTR) || (status == ETIMEDOUT))) {
1598 if (status == ETIMEDOUT) {
1676 int status;
1743 status = pthread_cond_signal(&th->th.th_suspend_cv.c_cond);
1744 KMP_CHECK_SYSFAIL("pthread_cond_signal", status);
1776 int status;
1783 status = pthread_mutex_lock(&__kmp_wait_mx.m_mutex);
1784 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
1793 status = pthread_cond_signal(&__kmp_wait_cv.c_cond);
1794 KMP_CHECK_SYSFAIL("pthread_cond_signal", status);
1795 status = pthread_mutex_unlock(&__kmp_wait_mx.m_mutex);
1796 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
1807 int status;
1808 status = pthread_setspecific(__kmp_gtid_threadprivate_key,
1810 KMP_CHECK_SYSFAIL("pthread_setspecific", status);
1845 int status;
1850 status = getrusage(RUSAGE_SELF, &r_usage);
1851 KMP_CHECK_SYSFAIL_ERRNO("getrusage", status);
1872 return (status != 0);
1879 int status;
1881 status = gettimeofday(&tval, NULL);
1882 KMP_CHECK_SYSFAIL_ERRNO("gettimeofday", status);
1890 int status;
1891 status = gettimeofday(&tval, NULL);
1892 KMP_CHECK_SYSFAIL_ERRNO("gettimeofday", status);
1942 int status;
1962 status = getrlimit(RLIMIT_STACK, &rlim);
1963 if (status == 0) { // success?
1999 status = pthread_key_create(&__kmp_gtid_threadprivate_key,
2001 KMP_CHECK_SYSFAIL("pthread_key_create", status);
2002 status = pthread_mutexattr_init(&mutex_attr);
2003 KMP_CHECK_SYSFAIL("pthread_mutexattr_init", status);
2004 status = pthread_mutex_init(&__kmp_wait_mx.m_mutex, &mutex_attr);
2005 KMP_CHECK_SYSFAIL("pthread_mutex_init", status);
2006 status = pthread_mutexattr_destroy(&mutex_attr);
2007 KMP_CHECK_SYSFAIL("pthread_mutexattr_destroy", status);
2008 status = pthread_condattr_init(&cond_attr);
2009 KMP_CHECK_SYSFAIL("pthread_condattr_init", status);
2010 status = pthread_cond_init(&__kmp_wait_cv.c_cond, &cond_attr);
2011 KMP_CHECK_SYSFAIL("pthread_cond_init", status);
2012 status = pthread_condattr_destroy(&cond_attr);
2013 KMP_CHECK_SYSFAIL("pthread_condattr_destroy", status);
2022 int status;
2032 status = pthread_key_delete(__kmp_gtid_threadprivate_key);
2033 KMP_CHECK_SYSFAIL("pthread_key_delete", status);
2035 status = pthread_mutex_destroy(&__kmp_wait_mx.m_mutex);
2036 if (status != 0 && status != EBUSY) {
2037 KMP_SYSFAIL("pthread_mutex_destroy", status);
2039 status = pthread_cond_destroy(&__kmp_wait_cv.c_cond);
2040 if (status != 0 && status != EBUSY) {
2041 KMP_SYSFAIL("pthread_cond_destroy", status);
2056 int status;
2060 status = clock_gettime(CLOCK_PROCESS_CPUTIME_ID, &ts);
2061 KMP_CHECK_SYSFAIL_ERRNO("clock_gettime", status);
2067 status = gettimeofday(&tv, NULL);
2068 KMP_CHECK_SYSFAIL_ERRNO("gettimeofday", status);
2675 Parsing "status" file looks more promissing (due to different
2677 parsing of "status" file works slower.
2909 int status = sem_wait(&hidden_helper_task_sem);
2910 KMP_CHECK_SYSFAIL("sem_wait", status);
2915 int status =
2917 KMP_CHECK_SYSFAIL("pthread_cond_init", status);
2919 status = pthread_cond_init(&hidden_helper_threads_deinitz_cond_var, nullptr);
2920 KMP_CHECK_SYSFAIL("pthread_cond_init", status);
2922 status = pthread_cond_init(&hidden_helper_main_thread_cond_var, nullptr);
2923 KMP_CHECK_SYSFAIL("pthread_cond_init", status);
2925 status = pthread_mutex_init(&hidden_helper_threads_initz_lock, nullptr);
2926 KMP_CHECK_SYSFAIL("pthread_mutex_init", status);
2928 status = pthread_mutex_init(&hidden_helper_threads_deinitz_lock, nullptr);
2929 KMP_CHECK_SYSFAIL("pthread_mutex_init", status);
2931 status = pthread_mutex_init(&hidden_helper_main_thread_lock, nullptr);
2932 KMP_CHECK_SYSFAIL("pthread_mutex_init", status);
2935 status = sem_init(&hidden_helper_task_sem, 0, 0);
2936 KMP_CHECK_SYSFAIL("sem_init", status);
2940 status = pthread_create(
2947 KMP_CHECK_SYSFAIL("pthread_create", status);
2953 int status = pthread_mutex_lock(&hidden_helper_threads_initz_lock);
2954 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
2957 status = pthread_cond_wait(&hidden_helper_threads_initz_cond_var,
2959 KMP_CHECK_SYSFAIL("pthread_cond_wait", status);
2962 status = pthread_mutex_unlock(&hidden_helper_threads_initz_lock);
2963 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
2968 int status = pthread_mutex_lock(&hidden_helper_threads_initz_lock);
2969 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
2971 status = pthread_cond_signal(&hidden_helper_threads_initz_cond_var);
2972 KMP_CHECK_SYSFAIL("pthread_cond_wait", status);
2976 status = pthread_mutex_unlock(&hidden_helper_threads_initz_lock);
2977 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
2983 int status = pthread_mutex_lock(&hidden_helper_main_thread_lock);
2984 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
2987 status = pthread_cond_wait(&hidden_helper_main_thread_cond_var,
2989 KMP_CHECK_SYSFAIL("pthread_cond_wait", status);
2992 status = pthread_mutex_unlock(&hidden_helper_main_thread_lock);
2993 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
2999 int status = pthread_mutex_lock(&hidden_helper_main_thread_lock);
3000 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
3002 status = pthread_cond_signal(&hidden_helper_main_thread_cond_var);
3003 KMP_CHECK_SYSFAIL("pthread_cond_signal", status);
3008 status = pthread_mutex_unlock(&hidden_helper_main_thread_lock);
3009 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
3013 int status = sem_post(&hidden_helper_task_sem);
3014 KMP_CHECK_SYSFAIL("sem_post", status);
3020 int status = pthread_mutex_lock(&hidden_helper_threads_deinitz_lock);
3021 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
3024 status = pthread_cond_wait(&hidden_helper_threads_deinitz_cond_var,
3026 KMP_CHECK_SYSFAIL("pthread_cond_wait", status);
3029 status = pthread_mutex_unlock(&hidden_helper_threads_deinitz_lock);
3030 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);
3034 int status = pthread_mutex_lock(&hidden_helper_threads_deinitz_lock);
3035 KMP_CHECK_SYSFAIL("pthread_mutex_lock", status);
3037 status = pthread_cond_signal(&hidden_helper_threads_deinitz_cond_var);
3038 KMP_CHECK_SYSFAIL("pthread_cond_wait", status);
3042 status = pthread_mutex_unlock(&hidden_helper_threads_deinitz_lock);
3043 KMP_CHECK_SYSFAIL("pthread_mutex_unlock", status);