- client: when estimating job runtime based on fraction done,

use the elapsed time when fraction done was last reported,
    not current elapsed time.
    Fix problem where est time remaining increases linearly,
    then abruptly decreases when new frac done is reported.
    From Bruce Allen.


svn path=/trunk/boinc/; revision=23373
This commit is contained in:
David Anderson 2011-04-18 16:32:57 +00:00
parent dc02d192a6
commit b89ea98838
4 changed files with 20 additions and 2 deletions

View File

@ -2279,3 +2279,16 @@ David 15 Apr 2011
client/
cs_notice.cpp
David 18 Apr 2011
- client: when estimating job runtime based on fraction done,
use the elapsed time when fraction done was last reported,
not current elapsed time.
Fix problem where est time remaining increases linearly,
then abruptly decreases when new frac done is reported.
From Bruce Allen.
client/
app.h
app_control.cpp
work_fetch.cpp

View File

@ -85,6 +85,8 @@ struct ACTIVE_TASK {
// App's estimate of how much of the work unit is done.
// Passed from the application via an API call;
// will be zero if the app doesn't use this call
double fraction_done_elapsed_time;
// elapsed time when fraction done was last reported
double current_cpu_time;
// most recent CPU time reported by app
bool once_ran_edf;

View File

@ -1065,7 +1065,10 @@ bool ACTIVE_TASK::get_app_status_msg() {
// until the app's first call to boinc_fraction_done().
// So ignore zeros.
//
if (fd) fraction_done = fd;
if (fd) {
fraction_done = fd;
fraction_done_elapsed_time = elapsed_time;
}
}
parse_double(msg_buf, "<current_cpu_time>", current_cpu_time);
parse_double(msg_buf, "<checkpoint_cpu_time>", checkpoint_cpu_time);

View File

@ -1322,7 +1322,7 @@ double ACTIVE_TASK::est_dur() {
double wu_est = result->estimated_duration();
if (fraction_done <= 0) return wu_est;
if (wu_est < elapsed_time) wu_est = elapsed_time;
double frac_est = elapsed_time / fraction_done;
double frac_est = fraction_done_elapsed_time / fraction_done;
double fraction_left = 1-fraction_done;
double wu_weight = fraction_left * fraction_left * fraction_left;
double fd_weight = 1 - wu_weight;