------- Comment #1 from bkoz at gcc dot gnu dot org 2007-10-09 22:24 -------
Ah yes, this one. I believe there is controversy around this implementation point on linux as well. Here's some info from previous discussions between myself, Ulrich, and Johannes. Me: Include <sched.h> for sched_yield in <parallel/compatibility.h>. Should this be pthread_yield or other approaches? Uli: Using sched_yield/pthread_yield is almost always wrong. I'd have to look at the specific code. If you can summarize it I can easily answer questions. Johannes: Well, it really helps for work-stealing algorithms, in particular if they use more threads than there are processors available at the time, which can change even during execution. It makes some decision based on the current load on the machine, which requires some OS interaction. That's the easiest and most robust way to do it. It is probably time to resume this discussion. -- bkoz at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |bkoz at gcc dot gnu dot org |dot org | Status|UNCONFIRMED |ASSIGNED Ever Confirmed|0 |1 Last reconfirmed|0000-00-00 00:00:00 |2007-10-09 22:24:54 date| | Summary|libstdc++ parallel mode |__gnu_parallel::yield broken |broken on mingw32 |on mingw32 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33578