I am working with sources of gcc-4.7.4
compiler. I must to learn work of OpenMP
libraries and I have read documentations of different versions of OpenMP and I didn't find any information about wok stealing mechanism. Is that true, that OpenMP does not support work stealing mechanism?
Asked
Active
Viewed 1,432 times
7

Musta Avaruus
- 103
- 5
1 Answers
5
OpenMP takes almost all of the responsibility for work scheduling out of the hands of the programmer. There is no explicit support for work-stealing, nor any other scheduling policy save for specifying how loop iterations are to be divided across processors.
However, an OpenMP implementation may choose to use work-stealing. The approach would be entirely suitable for the explicit task
construct that OpenMP supports. Equally, an implementation may choose another scheduling approach.
I have read that the gcc implementation does use work-stealing, but it's not something I've looked into and I may be wrong.

High Performance Mark
- 77,191
- 7
- 105
- 161
-
3I must admit I had never heard of [work stealing](https://en.wikipedia.org/wiki/Work_stealing) until now. It would be nice to describe what it is and how it contrasts to work sharing. – Z boson Apr 04 '16 at 18:02
-
1Work stealing sounds vaguely like the stack based method I used [here](http://stackoverflow.com/questions/35675466/reductions-in-parallel-in-logarithmic-time). – Z boson Apr 04 '16 at 18:06
-
@Zboson: well, the Wikipedia article you link to provides the nice descriptions you seek. – High Performance Mark Apr 04 '16 at 19:56