From ddc76d9587caae82cf321684e2b216efb997c04b Mon Sep 17 00:00:00 2001 From: David Anderson Date: Wed, 21 Jun 2006 23:16:46 +0000 Subject: [PATCH] *** empty log message *** svn path=/trunk/boinc/; revision=10445 --- checkin_notes | 7 +++++++ client/cpu_sched.C | 24 +++++++++++++++++++----- client/cs_scheduler.C | 16 ++++++++-------- doc/boinc_news.inc | 4 ++++ doc/client_msgs.php | 6 +++++- doc/sched.php | 2 +- 6 files changed, 44 insertions(+), 15 deletions(-) diff --git a/checkin_notes b/checkin_notes index 08a5d74280..24ebe34430 100755 --- a/checkin_notes +++ b/checkin_notes @@ -6544,3 +6544,10 @@ David 21 June 2006 cs_scheduler.C log_flags.C,h time_stats.C + +David 21 June 2006 + - core client: add some logging messages to rr_simulation() + + client/ + cpu_sched.C + cs_scheduler.C diff --git a/client/cpu_sched.C b/client/cpu_sched.C index 46a0c72503..3b75109b36 100644 --- a/client/cpu_sched.C +++ b/client/cpu_sched.C @@ -278,7 +278,7 @@ void CLIENT_STATE::adjust_debts() { p->anticipated_debt = 0; } scope_messages.printf( - "CLIENT_STATE::adjust_debts(): project %s: short-term debt %f\n", + "adjust_debts(): project %s: short-term debt %f\n", p->project_name, p->short_term_debt ); } @@ -395,7 +395,7 @@ void CLIENT_STATE::schedule_cpus() { // do round-robin simulation to find what results miss deadline, // - scope_messages.printf("rr_sim: calling from cpu_scheduler"); + scope_messages.printf("rr_simulation: calling from cpu_scheduler\n"); rr_simulation(avg_proc_rate()/ncpus, runnable_resource_share()); if (log_flags.cpu_sched_debug) { print_deadline_misses(); @@ -735,6 +735,8 @@ bool CLIENT_STATE::rr_simulation(double per_cpu_proc_rate, double rrs) { SCOPE_MSG_LOG scope_messages(log_messages, CLIENT_MSG_LOG::DEBUG_CPU_SCHED); + scope_messages.printf( "rr_simulation: start\n"); + // Initialize the "active" and "pending" lists for each project. // These keep track of that project's results // @@ -791,7 +793,8 @@ bool CLIENT_STATE::rr_simulation(double per_cpu_proc_rate, double rrs) { double diff = sim_now + rpbest->rrsim_finish_delay - rpbest->computation_deadline(); if (diff > 0) { scope_messages.printf( - "rr_sim: result %s misses deadline by %f\n", rpbest->name, diff + "rr_simulation: result %s misses deadline by %f\n", + rpbest->name, diff ); rpbest->rr_sim_misses_deadline = true; pbest->rr_sim_deadlines_missed++; @@ -867,8 +870,19 @@ bool CLIENT_STATE::rr_simulation(double per_cpu_proc_rate, double rrs) { sim_now += rpbest->rrsim_finish_delay; } - if (!rval) { - scope_messages.printf( "rr_sim: deadlines met\n"); + if (log_flags.cpu_sched_debug) { + for (i=0; iproject_name, p->cpu_shortfall + ); + } + msg_printf(NULL, MSG_INFO, + "rr_simulation: end; returning %s; cpu_shortfall %f\n", + rval?"true":"false", + cpu_shortfall + ); } return rval; } diff --git a/client/cs_scheduler.C b/client/cs_scheduler.C index a5ec483ae7..079975ad5f 100644 --- a/client/cs_scheduler.C +++ b/client/cs_scheduler.C @@ -612,13 +612,13 @@ int CLIENT_STATE::compute_work_requests() { if (estimated_time_to_starvation < work_min_period) { if (estimated_time_to_starvation == 0) { scope_messages.printf( - "CLIENT_STATE::compute_work_requests(): project '%s' is starved\n", + "compute_work_requests(): project '%s' is starved\n", p->project_name ); p->work_request_urgency = WORK_FETCH_NEED_IMMEDIATELY; } else { scope_messages.printf( - "CLIENT_STATE::compute_work_requests(): project '%s' will starve in %.2f sec\n", + "compute_work_requests(): project '%s' will starve in %.2f sec\n", p->project_name, estimated_time_to_starvation ); p->work_request_urgency = WORK_FETCH_NEED; @@ -640,13 +640,13 @@ int CLIENT_STATE::compute_work_requests() { } scope_messages.printf( - "CLIENT_STATE::compute_work_requests(): project %s work req: %f sec urgency: %d\n", + "compute_work_requests(): project %s work req: %f sec urgency: %d\n", p->project_name, p->work_request, p->work_request_urgency ); } scope_messages.printf( - "CLIENT_STATE::compute_work_requests(): client work need: %f sec, urgency %d\n", + "compute_work_requests(): client work need: %f sec, urgency %d\n", global_work_need, overall_work_fetch_urgency ); @@ -1034,7 +1034,7 @@ int CLIENT_STATE::handle_scheduler_reply( for (i=0; irunnable()) { rrs += p->resource_share; diff --git a/doc/boinc_news.inc b/doc/boinc_news.inc index 2e8417770d..bd63a24577 100644 --- a/doc/boinc_news.inc +++ b/doc/boinc_news.inc @@ -1,6 +1,10 @@ in Japanese." +), array("June 15, 2006", "BOINC's CPU scheduler has become smarter: it now waits until an application has checkpointed diff --git a/doc/client_msgs.php b/doc/client_msgs.php index 43a938fbe2..57a44cee31 100644 --- a/doc/client_msgs.php +++ b/doc/client_msgs.php @@ -9,6 +9,7 @@ This file has the following format: [ N ] [ 0|1 ] + [ N ] [ flags ] @@ -22,7 +23,10 @@ list_item_func("", Default is 30." ); list_item_func("", - " If nonzero, don't check file sizes" + "If nonzero, don't check file sizes" +); +list_item_func("", + "Act as if there were N CPUs (for debugging)." ); list_end(); echo " diff --git a/doc/sched.php b/doc/sched.php index 663a7a5dd3..ea51b591e3 100644 --- a/doc/sched.php +++ b/doc/sched.php @@ -270,7 +270,7 @@ Tiebreaker: least index in result array.
  • Find the project P with the greatest anticipated debt, select one of P's runnable results (picking one that is already running, if possible, -else the result with earliest deadline) +else the one received first from the project) and schedule that result.
  • Decrement P's anticipated debt by the 'expected payoff' (the scheduling period divided by NCPUS).