mirror of https://github.com/BOINC/boinc.git
svn path=/trunk/boinc/; revision=24537
This commit is contained in:
parent
5b04b249db
commit
98ba6807ab
|
@ -8169,8 +8169,15 @@ David 5 Nov 2011
|
||||||
client/
|
client/
|
||||||
cs_trickle.cpp
|
cs_trickle.cpp
|
||||||
|
|
||||||
David 5 Nov 2011
|
David 6 Nov 2011
|
||||||
- client: actually do the checking described above
|
- client: actually do the checking described above
|
||||||
|
|
||||||
client/
|
client/
|
||||||
cs_trickle.cpp
|
cs_trickle.cpp
|
||||||
|
|
||||||
|
David 6 Nov 2011
|
||||||
|
- client: don't crash if a project sends app_version.flops = 0.
|
||||||
|
|
||||||
|
client/
|
||||||
|
client_types.cpp
|
||||||
|
rr_sim.cpp
|
||||||
|
|
|
@ -1268,6 +1268,7 @@ int FILE_INFO::gzip() {
|
||||||
|
|
||||||
int APP_VERSION::parse(XML_PARSER& xp) {
|
int APP_VERSION::parse(XML_PARSER& xp) {
|
||||||
FILE_REF file_ref;
|
FILE_REF file_ref;
|
||||||
|
double dtemp;
|
||||||
|
|
||||||
strcpy(app_name, "");
|
strcpy(app_name, "");
|
||||||
strcpy(api_version, "");
|
strcpy(api_version, "");
|
||||||
|
@ -1302,7 +1303,16 @@ int APP_VERSION::parse(XML_PARSER& xp) {
|
||||||
if (xp.parse_str("plan_class", plan_class, sizeof(plan_class))) continue;
|
if (xp.parse_str("plan_class", plan_class, sizeof(plan_class))) continue;
|
||||||
if (xp.parse_double("avg_ncpus", avg_ncpus)) continue;
|
if (xp.parse_double("avg_ncpus", avg_ncpus)) continue;
|
||||||
if (xp.parse_double("max_ncpus", max_ncpus)) continue;
|
if (xp.parse_double("max_ncpus", max_ncpus)) continue;
|
||||||
if (xp.parse_double("flops", flops)) continue;
|
if (xp.parse_double("flops", dtemp)) {
|
||||||
|
if (dtemp <= 0) {
|
||||||
|
msg_printf(0, MSG_INTERNAL_ERROR,
|
||||||
|
"non-positive FLOPS in app version"
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
flops = dtemp;
|
||||||
|
}
|
||||||
|
continue;
|
||||||
|
}
|
||||||
if (xp.parse_str("cmdline", cmdline, sizeof(cmdline))) continue;
|
if (xp.parse_str("cmdline", cmdline, sizeof(cmdline))) continue;
|
||||||
if (xp.parse_str("file_prefix", file_prefix, sizeof(file_prefix))) continue;
|
if (xp.parse_str("file_prefix", file_prefix, sizeof(file_prefix))) continue;
|
||||||
if (xp.parse_double("gpu_ram", gpu_ram)) continue;
|
if (xp.parse_double("gpu_ram", gpu_ram)) continue;
|
||||||
|
|
|
@ -96,6 +96,9 @@ void set_rrsim_flops(RESULT* rp) {
|
||||||
} else {
|
} else {
|
||||||
rp->rrsim_flops = rp->avp->flops * gstate.overall_cpu_frac();
|
rp->rrsim_flops = rp->avp->flops * gstate.overall_cpu_frac();
|
||||||
}
|
}
|
||||||
|
if (rp->rrsim_flops == 0) {
|
||||||
|
rp->rrsim_flops = 1e6; // just in case
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void print_deadline_misses() {
|
void print_deadline_misses() {
|
||||||
|
@ -346,11 +349,9 @@ void RR_SIM::simulate() {
|
||||||
rpbest = NULL;
|
rpbest = NULL;
|
||||||
for (u=0; u<active.size(); u++) {
|
for (u=0; u<active.size(); u++) {
|
||||||
rp = active[u];
|
rp = active[u];
|
||||||
if (rp->rrsim_flops) {
|
rp->rrsim_finish_delay = rp->rrsim_flops_left/rp->rrsim_flops;
|
||||||
rp->rrsim_finish_delay = rp->rrsim_flops_left/rp->rrsim_flops;
|
if (!rpbest || rp->rrsim_finish_delay < rpbest->rrsim_finish_delay) {
|
||||||
if (!rpbest || rp->rrsim_finish_delay < rpbest->rrsim_finish_delay) {
|
rpbest = rp;
|
||||||
rpbest = rp;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue