Browse Source

bug fix with dirty hack for calibrating.
I dont know how to manage calibration and no perf models tasks nicely

Simon Archipoff 12 years ago
parent
commit
89673637e9

+ 1 - 0
src/sched_policies/node_best_implementation.c

@@ -55,6 +55,7 @@ static int select_best_implementation_push_task(struct starpu_sched_node * node,
 static struct starpu_task * select_best_implementation_pop_task(struct starpu_sched_node * node, unsigned sched_ctx_id)
 static struct starpu_task * select_best_implementation_pop_task(struct starpu_sched_node * node, unsigned sched_ctx_id)
 {
 {
 	struct starpu_task * t;
 	struct starpu_task * t;
+	STARPU_ASSERT(node->is_homogeneous);
 	if(!node->fathers[sched_ctx_id])
 	if(!node->fathers[sched_ctx_id])
 		return NULL;
 		return NULL;
 	t = node->fathers[sched_ctx_id]->pop_task(node->fathers[sched_ctx_id], sched_ctx_id);
 	t = node->fathers[sched_ctx_id]->pop_task(node->fathers[sched_ctx_id], sched_ctx_id);

+ 1 - 0
src/sched_policies/node_heft.c

@@ -211,6 +211,7 @@ static void initialize_heft_center_policy(unsigned sched_ctx_id)
 
 
 		struct starpu_sched_node * calibration_node = starpu_sched_node_calibration_create(NULL);
 		struct starpu_sched_node * calibration_node = starpu_sched_node_calibration_create(NULL);
 		starpu_sched_node_add_child(calibration_node, worker_node);
 		starpu_sched_node_add_child(calibration_node, worker_node);
+		calibration_node->workers_in_ctx = impl_node->workers;
 		starpu_sched_node_add_child(random, calibration_node);
 		starpu_sched_node_add_child(random, calibration_node);
 
 
 
 

+ 1 - 1
src/sched_policies/node_sched.c

@@ -448,7 +448,7 @@ void starpu_sched_node_init_rec(struct starpu_sched_node * node)
 
 
 	for(i = 0; i < node->nchilds; i++)
 	for(i = 0; i < node->nchilds; i++)
 		starpu_bitmap_or(node->workers, node->childs[i]->workers);
 		starpu_bitmap_or(node->workers, node->childs[i]->workers);
-
+	set_is_homogeneous(node);
 	if(node->init_data)
 	if(node->init_data)
 		node->init_data(node);
 		node->init_data(node);
 }
 }