- client: garbage collect after scheduler RPC;

if project sent some irrelevant FILE_INFOs,
		this will avoid starting transfers for them.

svn path=/trunk/boinc/; revision=17644
This commit is contained in:
David Anderson 2009-03-23 01:33:17 +00:00
parent b340d016c2
commit 5a5b386313
5 changed files with 21 additions and 3 deletions

View File

@ -887,7 +887,7 @@ static void timer_handler() {
if (interrupt_count % TIMERS_PER_SEC) return;
#ifdef DEBUG
fprintf(stderr, "%f: 1 sec elapsed\n");
fprintf(stderr, "%f: 1 sec elapsed\n", dtime());
#endif
// here it we're at a one-second boundary; do slow stuff

View File

@ -3207,3 +3207,16 @@ David 20 Mar 2009
html/inc/
host.inc
David 20 Mar 2009
- client: garbage collect after scheduler RPC;
if project sent some irrelevant FILE_INFOs,
this will avoid starting transfers for them.
api/
boinc_api.cpp
client/
cs_scheduler.cpp
gui_rpc_server_ops.cpp
samples/multi_thread/
multi_thread.cpp

View File

@ -950,6 +950,11 @@ int CLIENT_STATE::handle_scheduler_reply(PROJECT* project, char* scheduler_url)
project->set_min_rpc_time(x, "requested by project");
}
// garbage collect in case the project sent us some irrelevant FILE_INFOs;
// avoid starting transfers for them
//
gstate.garbage_collect_always();
return 0;
}

View File

@ -910,7 +910,7 @@ static void read_all_projects_list_file(MIOFILE& fout) {
static int set_debt(XML_PARSER& xp) {
bool is_tag;
char tag[256], url[256];
double short_term_debt = 0.0, long_term_debt = 0.0, cuda_debt;
double short_term_debt = 0, long_term_debt = 0, cuda_debt=0;
bool got_std=false, got_ltd=false, got_cuda_debt=false;
strcpy(url, "");
while (!xp.get(tag, sizeof(tag), is_tag)) {

View File

@ -171,7 +171,7 @@ void* worker(void* p) {
for (int i=0; i<units_per_thread; i++) {
double x = do_a_giga_flop(i);
t->units_done++;
fprintf(stderr, "thread %d finished %d: %f\n", t->index, i, x);
fprintf(stderr, "%f: thread %d finished %d: %f\n", dtime(), t->index, i, x);
}
t->id = THREAD_ID_NULL;
#ifdef _WIN32