MAOS
Multithreaded Adaptive Optics Simulator
|
Macros | |
#define | print_mem(A, ...) info(A ":\t%.1f MiB.\n", ##__VA_ARGS__, get_job_mem()/1024.); |
Functions | |
void | init_process (void) |
void | free_process (void) |
int | get_usage_running (void) |
double | get_usage_load (void) |
double | get_usage_mem (void) |
double | get_usage_cpu (void) |
int | get_job_progname (char *res, int nres, int pid) |
size_t | get_job_mem (void) |
double | get_job_launchtime (int pid) |
int | get_cpu_avail (void) |
int | read_cpu_counter (long *user, long *tot) |
double | read_self_cpu (void) |
int | get_ncpu (void) |
void | set_dirout (const char *dir) |
A few routines handles process resource.
void init_process | ( | void | ) |
Set the HOME, TEMP, USER names.
void free_process | ( | void | ) |
free memory
double get_usage_cpu | ( | void | ) |
Obtain the current usage level of CPU, between 0 and 1.
int get_cpu_avail | ( | void | ) |
Return number of idle CPUs that are available to run jobs. Do not count hyperthread cores.