News for hackers. Stuff that matters.
Re:Parallelizing the Naughty Dog Engine Using Fibers [video] by rawnlq on Thursday May 26, 2016 @06:43PM (#11782281)
An older but similar approach from Doom III engine: http://fabiensanglard.net/doom3_bfg/threading.php

I wonder if there is a good open-sourced C++11 project for this pattern? (a job/task queue)

Also how does this pattern compare with just using future/promises with a parallel executor?

https://code.facebook.com/posts/1661982097368498/futures-for...

or grand central dispatch from objective C?

Re:Parallelizing the Naughty Dog Engine Using Fibers [video] by lbrandy on Thursday May 26, 2016 @07:14PM (#11782463)
Our (facebook's) folly library has lots of components for doing stuff using fibers[1]. That sits with folly::futures[2] and wangle[3].

That said, without proper language/compiler support, though, it's difficult to make them "safe" (for some definition). Even within fb, given these libraries, we are pretty wary of using fibers with C++ unless absolutely necessary. You gotta really need it. This is where the coroutines proposals working their way through the C++ committee can make lives better.

[1] https://github.com/facebook/folly/tree/master/folly/fibers

[2] https://github.com/facebook/folly/tree/master/folly/futures

[3] https://github.com/facebook/wangle