Sfoglia il codice sorgente

sc_hypervisor: fix multiple definition

Nathalie Furmento 6 anni fa
parent
commit
307e742f81

+ 1 - 1
sc_hypervisor/include/sc_hypervisor.h

@@ -30,7 +30,7 @@ extern "C"
 #endif
 #endif
 
 
 /* synchronise the hypervisor when several workers try to update its information */
 /* synchronise the hypervisor when several workers try to update its information */
-starpu_pthread_mutex_t act_hypervisor_mutex;
+extern starpu_pthread_mutex_t act_hypervisor_mutex;
 
 
 /* platform of resizing contexts */
 /* platform of resizing contexts */
 struct sc_hypervisor_policy
 struct sc_hypervisor_policy

+ 1 - 0
sc_hypervisor/src/sc_hypervisor.c

@@ -20,6 +20,7 @@
 #include <sc_hypervisor_policy.h>
 #include <sc_hypervisor_policy.h>
 #include <starpu_config.h>
 #include <starpu_config.h>
 
 
+starpu_pthread_mutex_t act_hypervisor_mutex;
 double hyp_overhead = 0.0;
 double hyp_overhead = 0.0;
 unsigned imposed_resize = 0;
 unsigned imposed_resize = 0;
 unsigned type_of_tasks_known = 0;
 unsigned type_of_tasks_known = 0;