#include "libgomp.h"
#include "libgomp_f.h"
#include <ctype.h>
#include <stdlib.h>
#include <limits.h>
#include <errno.h>
Include dependency graph for env.c:
Go to the source code of this file.
Defines | |
#define | strtoull(ptr, eptr, base) strtoul (ptr, eptr, base) |
Functions | |
static void | parse_schedule (void) |
static bool | parse_unsigned_long (const char *name, unsigned long *pvalue, bool allow_zero) |
static bool | parse_stacksize (const char *name, unsigned long *pvalue) |
static bool | parse_spincount (const char *name, unsigned long long *pvalue) |
static void | parse_boolean (const char *name, bool *value) |
static int | parse_wait_policy (void) |
static bool | parse_affinity (void) |
static void | __attribute__ ((constructor)) |
void | omp_set_num_threads (int n) |
void | omp_set_dynamic (int val) |
int | omp_get_dynamic (void) |
void | omp_set_nested (int val) |
int | omp_get_nested (void) |
void | omp_set_schedule (omp_sched_t kind, int modifier) |
void | omp_get_schedule (omp_sched_t *kind, int *modifier) |
int | omp_get_max_threads (void) |
int | omp_get_thread_limit (void) |
void | omp_set_max_active_levels (int max_levels) |
int | omp_get_max_active_levels (void) |
Variables | |
gomp_task_icv | gomp_global_icv |
unsigned short * | gomp_cpu_affinity |
size_t | gomp_cpu_affinity_len |
unsigned long | gomp_max_active_levels_var = INT_MAX |
unsigned long | gomp_thread_limit_var = ULONG_MAX |
unsigned long | gomp_remaining_threads_count |
gomp_mutex_t | gomp_remaining_threads_lock |
unsigned long | gomp_available_cpus = 1 |
unsigned long | gomp_managed_threads = 1 |
unsigned long long | gomp_spin_count_var |
unsigned long long | gomp_throttled_spin_count_var |
static void __attribute__ | ( | (constructor) | ) | [static] |
Definition at line 473 of file env.c.
References gomp_task_icv::dyn_var, err, gomp_available_cpus, gomp_error(), gomp_global_icv, gomp_init_affinity(), gomp_init_num_threads(), gomp_max_active_levels_var, gomp_mutex_init(), gomp_remaining_threads_count, gomp_remaining_threads_lock, gomp_spin_count_var, gomp_thread_attr, gomp_thread_limit_var, gomp_throttled_spin_count_var, gomp_task_icv::nest_var, gomp_task_icv::nthreads_var, parse_affinity(), parse_boolean(), parse_schedule(), parse_spincount(), parse_stacksize(), parse_unsigned_long(), and parse_wait_policy().
Here is the call graph for this function:
int omp_get_dynamic | ( | void | ) |
Definition at line 569 of file env.c.
References gomp_task_icv::dyn_var, and gomp_icv().
Referenced by main(), and omp_get_dynamic_().
Here is the call graph for this function:
Here is the caller graph for this function:
int omp_get_max_active_levels | ( | void | ) |
Definition at line 643 of file env.c.
References gomp_max_active_levels_var.
Referenced by main(), and omp_get_max_active_levels_().
Here is the caller graph for this function:
int omp_get_max_threads | ( | void | ) |
Definition at line 623 of file env.c.
References gomp_icv(), and gomp_task_icv::nthreads_var.
Referenced by main(), omp_get_max_threads_(), and tf().
Here is the call graph for this function:
Here is the caller graph for this function:
int omp_get_nested | ( | void | ) |
Definition at line 583 of file env.c.
References gomp_icv(), and gomp_task_icv::nest_var.
Referenced by main(), omp_get_nested_(), and work().
Here is the call graph for this function:
Here is the caller graph for this function:
void omp_get_schedule | ( | omp_sched_t * | kind, | |
int * | modifier | |||
) |
Definition at line 615 of file env.c.
References gomp_icv(), gomp_task_icv::run_sched_modifier, and gomp_task_icv::run_sched_var.
Referenced by main(), omp_get_schedule_(), and omp_get_schedule_8_().
Here is the call graph for this function:
Here is the caller graph for this function:
int omp_get_thread_limit | ( | void | ) |
Definition at line 630 of file env.c.
References gomp_thread_limit_var, and INT_MAX.
Referenced by main(), and omp_get_thread_limit_().
Here is the caller graph for this function:
void omp_set_dynamic | ( | int | val | ) |
Definition at line 562 of file env.c.
References gomp_task_icv::dyn_var, and gomp_icv().
Referenced by a36(), foo(), main(), omp_set_dynamic_(), omp_set_dynamic_8_(), and tf().
Here is the call graph for this function:
Here is the caller graph for this function:
void omp_set_max_active_levels | ( | int | max_levels | ) |
Definition at line 636 of file env.c.
References gomp_max_active_levels_var.
Referenced by main(), omp_set_max_active_levels_(), and omp_set_max_active_levels_8_().
Here is the caller graph for this function:
void omp_set_nested | ( | int | val | ) |
Definition at line 576 of file env.c.
References gomp_icv(), and gomp_task_icv::nest_var.
Referenced by foo(), main(), omp_set_nested_(), and omp_set_nested_8_().
Here is the call graph for this function:
Here is the caller graph for this function:
void omp_set_num_threads | ( | int | n | ) |
Definition at line 555 of file env.c.
References gomp_icv(), and gomp_task_icv::nthreads_var.
Referenced by a36(), main(), omp_set_num_threads_(), omp_set_num_threads_8_(), and tf().
Here is the call graph for this function:
Here is the caller graph for this function:
void omp_set_schedule | ( | omp_sched_t | kind, | |
int | modifier | |||
) |
Definition at line 590 of file env.c.
References gomp_icv(), gomp_task_icv::run_sched_modifier, and gomp_task_icv::run_sched_var.
Referenced by main(), omp_set_schedule_(), and omp_set_schedule_8_().
Here is the call graph for this function:
Here is the caller graph for this function:
static bool parse_affinity | ( | void | ) | [static] |
Definition at line 386 of file env.c.
References gomp_cpu_affinity, gomp_cpu_affinity_len, and gomp_error().
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
static void parse_boolean | ( | const char * | name, | |
bool * | value | |||
) | [static] |
Definition at line 319 of file env.c.
References gomp_error().
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
static void parse_schedule | ( | void | ) | [static] |
Definition at line 74 of file env.c.
References GFS_AUTO, GFS_DYNAMIC, GFS_GUIDED, GFS_STATIC, gomp_error(), gomp_global_icv, gomp_task_icv::run_sched_modifier, and gomp_task_icv::run_sched_var.
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
static bool parse_spincount | ( | const char * | name, | |
unsigned long long * | pvalue | |||
) | [static] |
Definition at line 246 of file env.c.
References gomp_error(), and strtoull.
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
static bool parse_stacksize | ( | const char * | name, | |
unsigned long * | pvalue | |||
) | [static] |
Definition at line 185 of file env.c.
References gomp_error().
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
static bool parse_unsigned_long | ( | const char * | name, | |
unsigned long * | pvalue, | |||
bool | allow_zero | |||
) | [static] |
Definition at line 149 of file env.c.
References gomp_error().
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
static int parse_wait_policy | ( | void | ) | [static] |
Definition at line 351 of file env.c.
References gomp_error().
Referenced by __attribute__().
Here is the call graph for this function:
Here is the caller graph for this function:
unsigned long gomp_available_cpus = 1 |
unsigned short* gomp_cpu_affinity |
size_t gomp_cpu_affinity_len |
struct gomp_task_icv gomp_global_icv |
Initial value:
{ .nthreads_var = 1, .run_sched_var = GFS_DYNAMIC, .run_sched_modifier = 1, .dyn_var = false, .nest_var = false }
Definition at line 52 of file env.c.
Referenced by __attribute__(), gomp_icv(), gomp_init_num_threads(), gomp_new_icv(), gomp_team_start(), and parse_schedule().
unsigned long gomp_managed_threads = 1 |
unsigned long gomp_max_active_levels_var = INT_MAX |
Definition at line 62 of file env.c.
Referenced by __attribute__(), gomp_resolve_num_threads(), omp_get_max_active_levels(), and omp_set_max_active_levels().
unsigned long gomp_remaining_threads_count |
Definition at line 64 of file env.c.
Referenced by __attribute__(), GOMP_parallel_end(), and gomp_resolve_num_threads().
Definition at line 66 of file env.c.
Referenced by __attribute__(), GOMP_parallel_end(), gomp_resolve_num_threads(), and gomp_team_end().
unsigned long long gomp_spin_count_var |
unsigned long gomp_thread_limit_var = ULONG_MAX |
Definition at line 63 of file env.c.
Referenced by __attribute__(), GOMP_parallel_end(), gomp_resolve_num_threads(), and omp_get_thread_limit().
unsigned long long gomp_throttled_spin_count_var |