diff --git a/checkin_notes b/checkin_notes index b86eda9051..aa6c5b1180 100644 --- a/checkin_notes +++ b/checkin_notes @@ -10222,3 +10222,10 @@ David 17 Dec 2009 client/ cpu_sched.cpp + +David 17 Dec 2009 + - client: in computing "anticipated" STD, scale by ninstances + (from John McLeod) + + client/ + cpu_sched.cpp diff --git a/client/cpu_sched.cpp b/client/cpu_sched.cpp index 41ca57698b..e5894e7b19 100644 --- a/client/cpu_sched.cpp +++ b/client/cpu_sched.cpp @@ -635,9 +635,12 @@ static bool schedule_if_possible( } proc_rsc.schedule(rp); double dt = gstate.global_prefs.cpu_scheduling_period(); - rp->project->cpu_pwf.anticipated_debt -= dt*rp->avp->avg_ncpus; - rp->project->cuda_pwf.anticipated_debt -= dt*rp->avp->ncudas; - rp->project->ati_pwf.anticipated_debt -= dt*rp->avp->natis; + + // project STD at end of scheduling period + // + rp->project->cpu_pwf.anticipated_debt -= dt*rp->avp->avg_ncpus/cpu_work_fetch.ninstances; + rp->project->cuda_pwf.anticipated_debt -= dt*rp->avp->ncudas/cuda_work_fetch.ninstances; + rp->project->ati_pwf.anticipated_debt -= dt*rp->avp->natis/ati_work_fetch.ninstances; return true; }