21 #define NO_OF_CPUS sysconf(_SC_NPROCESSORS_CONF)
23 #define checkStatus(status,message) \
25 errlogPrintf("%s error %s\n", (message), strerror((status))); \
39 void strToCpuset(cpu_set_t *cpuset,
const char *spec);
40 void cpusetToStr(
char *set,
size_t len,
const cpu_set_t *cpuset);
void cpusetToStr(char *set, size_t len, const cpu_set_t *cpuset)
Convert a cpuset into its string specification (e.g. "0,2-3").
const char * policyToStr(const int policy)
Convert scheduling policy to string.
void strToCpuset(cpu_set_t *cpuset, const char *spec)
Convert a cpuset string specification (e.g. "0,2-3") to a cpuset.
int cpuDigits
Number of digits needed for a single CPU spec.
int strToPolicy(const char *string)
Convert string policy specification to policy.