From 7f6fe69e50599faf6bd3de683604f31b5fe8cf57 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Fri, 3 Feb 2006 08:36:00 +0000 Subject: [PATCH] LTD svn path=/trunk/boinc/; revision=9398 --- checkin_notes | 8 ++++++++ client/cs_apps.C | 9 ++++----- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/checkin_notes b/checkin_notes index 6470754d4a..1f77cd30c2 100755 --- a/checkin_notes +++ b/checkin_notes @@ -1436,3 +1436,11 @@ David 2 Feb 2005 client/ cs_apps.C + +David 2 Feb 2005 + - core client: long-term debt is modified only over + potentially runnable projects, + but it's averaged and normalized over all projects. + + client/ + cs_apps.C diff --git a/client/cs_apps.C b/client/cs_apps.C index e18543654b..e473cd53db 100644 --- a/client/cs_apps.C +++ b/client/cs_apps.C @@ -481,16 +481,16 @@ void CLIENT_STATE::adjust_debts() { for (i=0; inon_cpu_intensive) continue; + nprojects++; // adjust long-term debts // if (p->potentially_runnable() || p->wall_cpu_time_this_period) { - nprojects++; share_frac = p->resource_share/prrs; p->long_term_debt += share_frac*total_wall_cpu_time_this_period - p->wall_cpu_time_this_period; - total_long_term_debt += p->long_term_debt; } + total_long_term_debt += p->long_term_debt; // adjust short term debts // @@ -537,9 +537,8 @@ void CLIENT_STATE::adjust_debts() { p->anticipated_debt = p->short_term_debt; //msg_printf(p, MSG_INFO, "debt %f", p->short_term_debt); } - if (p->potentially_runnable() || p->wall_cpu_time_this_period) { - p->long_term_debt -= avg_long_term_debt; - } + + p->long_term_debt -= avg_long_term_debt; } }