Browse Source

Reduce synchronization for running flag

Samuel Thibault 12 years ago
parent
commit
f57b5615d9
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/core/workers.c

+ 2 - 2
src/core/workers.c

@@ -779,7 +779,7 @@ out:
 unsigned _starpu_machine_is_running(void)
 {
 	/* running is just protected by a memory barrier */
-	STARPU_SYNCHRONIZE();
+	STARPU_RMB();
 	return config.running;
 }
 
@@ -808,7 +808,7 @@ static void _starpu_kill_all_workers(struct _starpu_machine_config *config)
 	/* set the flag which will tell workers to stop */
 	config->running = 0;
 	/* running is just protected by a memory barrier */
-	STARPU_SYNCHRONIZE();
+	STARPU_WMB();
 	starpu_wake_all_blocked_workers();
 }