Re: [Algorithms] General purpose task parallel threading approach
Brought to you by:
vexxed72
|
From: Jon W. <jw...@gm...> - 2009-04-04 16:16:17
|
asy...@gm... wrote: > >Have you measured it? > I composed a quick sample - 2 threads which ping pong each other via 2 > events (1 core utilized in total), each thread did 10 million > iterations of passing execution to another thread (20 million > execution passes in total), and did the same test with tasks. I don't think that's a representative measurement, though, because it is the absolute best case: both contexts are in L1, on the same core. For any kind of real workload with blocking waits, that will not be the case. I believe the Windows kernel version will not slow down much in that case, but the asynclib version will. Of course, if your workload is actually highly cached and interdependent, then this measurement may be more relevant. Sincerely, jw |