[Omp] one thread stop another thread

Nils Smeds smeds at pdc.kth.se
Sun Dec 12 21:51:13 PST 2004


Using a boolean variable will do the trick if combined with the FLUSH directive
in both threads (after modifying the flag and before reading it).

Atomicity is not an issue here since it is a matter of setting a flag in one
thread and checking for a flag being set or not in another thread.

/Nils





More information about the Omp mailing list