mirror of https://github.com/BOINC/boinc.git
- client: fix exclusive_gpu_app feature so that it responds
within 10 sec instead of 60 sec svn path=/trunk/boinc/; revision=19577
This commit is contained in:
parent
329303b323
commit
98d9cfae6f
|
@ -9212,3 +9212,11 @@ Rom 13 Nov 2009
|
|||
boincsvcctrl.vcproj
|
||||
boinctray.vcproj
|
||||
libboinc.vcproj
|
||||
|
||||
David 13 Nov 2009
|
||||
- client: fix exclusive_gpu_app feature so that it responds
|
||||
within 10 sec instead of 60 sec
|
||||
|
||||
client/
|
||||
app.cpp
|
||||
log_flags.cpp
|
||||
|
|
|
@ -297,6 +297,7 @@ void ACTIVE_TASK_SET::free_mem() {
|
|||
bool app_running(vector<PROCINFO>& piv, const char* p) {
|
||||
for (unsigned int i=0; i<piv.size(); i++) {
|
||||
PROCINFO& pi = piv[i];
|
||||
//msg_printf(0, MSG_INFO, "running: [%s]", pi.command);
|
||||
if (!strcmp(pi.command, p)) {
|
||||
return true;
|
||||
}
|
||||
|
@ -348,6 +349,7 @@ void ACTIVE_TASK_SET::get_memory_usage() {
|
|||
}
|
||||
|
||||
exclusive_app_running = false;
|
||||
bool old_egar = exclusive_gpu_app_running;
|
||||
exclusive_gpu_app_running = false;
|
||||
for (i=0; i<config.exclusive_apps.size(); i++) {
|
||||
if (app_running(piv, config.exclusive_apps[i].c_str())) {
|
||||
|
@ -361,6 +363,9 @@ void ACTIVE_TASK_SET::get_memory_usage() {
|
|||
break;
|
||||
}
|
||||
}
|
||||
if (old_egar != exclusive_gpu_app_running) {
|
||||
gstate.request_schedule_cpus("Exclusive GPU app status changed");
|
||||
}
|
||||
|
||||
#if 0
|
||||
// the following is not useful because most OSs don't
|
||||
|
|
|
@ -172,6 +172,7 @@ static void show_gpu_ignore(vector<int>& devs, const char* name) {
|
|||
// TODO: show other config options
|
||||
//
|
||||
void CONFIG::show() {
|
||||
unsigned int i;
|
||||
if (config.ncpus>=0) {
|
||||
msg_printf(NULL, MSG_INFO, "Config: use at most %d CPUs", config.ncpus);
|
||||
}
|
||||
|
@ -192,6 +193,18 @@ void CONFIG::show() {
|
|||
}
|
||||
show_gpu_ignore(ignore_cuda_dev, "NVIDIA");
|
||||
show_gpu_ignore(ignore_ati_dev, "ATI");
|
||||
for (i=0; i<exclusive_apps.size(); i++) {
|
||||
msg_printf(NULL, MSG_INFO,
|
||||
"Config: don't compute while %s is running",
|
||||
exclusive_apps[i].c_str()
|
||||
);
|
||||
}
|
||||
for (i=0; i<exclusive_gpu_apps.size(); i++) {
|
||||
msg_printf(NULL, MSG_INFO,
|
||||
"Config: don't use GPUs while %s is running",
|
||||
exclusive_gpu_apps[i].c_str()
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
CONFIG::CONFIG() {
|
||||
|
|
Loading…
Reference in New Issue