client: add <dont_suspend_nci> config option.

If set, non-CPU-intensive jobs are exempted from mass suspend
(e.g. suspend CPU, time of day, CPU throttling).
You can still suspend them individually.
This commit is contained in:
David Anderson 2015-01-05 12:58:40 -08:00
parent 0e60404de9
commit fb31a869ed
4 changed files with 11 additions and 0 deletions

View File

@ -1155,6 +1155,10 @@ void ACTIVE_TASK_SET::suspend_all(int reason) {
continue;
}
if (cc_config.dont_suspend_nci && atp->result->non_cpu_intensive()) {
continue;
}
// handle CPU throttling separately
//
if (reason == SUSPEND_REASON_CPU_THROTTLE) {

View File

@ -314,6 +314,8 @@ struct APP_VERSION {
double missing_coproc_usage;
char missing_coproc_name[256];
bool dont_throttle;
// jobs of this app version are exempt from CPU throttling
// Set for coprocessor apps
bool is_vm_app;
// currently this set if plan class includes "vbox" (kludge)
bool is_wrapper;

View File

@ -208,6 +208,7 @@ void CC_CONFIG::defaults() {
disallow_attach = false;
dont_check_file_sizes = false;
dont_contact_ref_site = false;
dont_suspend_nci = false;
dont_use_vbox = false;
exclude_gpus.clear();
exclusive_apps.clear();
@ -338,6 +339,7 @@ int CC_CONFIG::parse_options(XML_PARSER& xp) {
if (xp.parse_bool("disallow_attach", disallow_attach)) continue;
if (xp.parse_bool("dont_check_file_sizes", dont_check_file_sizes)) continue;
if (xp.parse_bool("dont_contact_ref_site", dont_contact_ref_site)) continue;
if (xp.parse_bool("dont_suspend_nci", dont_suspend_nci)) continue;
if (xp.parse_bool("dont_use_vbox", dont_use_vbox)) continue;
if (xp.match_tag("exclude_gpu")) {
EXCLUDE_GPU eg;
@ -541,10 +543,12 @@ int CC_CONFIG::write(MIOFILE& out, LOG_FLAGS& log_flags) {
" <disallow_attach>%d</disallow_attach>\n"
" <dont_check_file_sizes>%d</dont_check_file_sizes>\n"
" <dont_contact_ref_site>%d</dont_contact_ref_site>\n"
" <dont_suspend_nci>%d</dont_suspend_nci>\n"
" <dont_use_vbox>%d</dont_use_vbox>\n",
disallow_attach,
dont_check_file_sizes,
dont_contact_ref_site,
dont_suspend_nci,
dont_use_vbox
);

View File

@ -149,6 +149,7 @@ struct CC_CONFIG {
bool disallow_attach;
bool dont_check_file_sizes;
bool dont_contact_ref_site;
bool dont_suspend_nci;
bool dont_use_vbox;
std::vector<EXCLUDE_GPU> exclude_gpus;
std::vector<std::string> exclusive_apps;