This version of Destroy the Castle was created to show how to parallel such a game application using OpenMP Tasks. The project is built using Intel(R) Parallel Studio Composer compiler.
Several weeks ago I did an unofficial google survey to see if there was much information on the topic of using OpenmP for games. There were not that many posts on the subject and most were rather negative on using OpenMP for games – and the general consensus was that OpenMP is fine for data decomposition of for loops only and since this does not apply to the main game loop this relegated OpenMP to a minor role for developing parallel games.
Most modern threading platforms are already offering task based programming models. Thus, they are allowing developers to follow one of the eight rules for multicore programming written by James Reinders a few years ago. I’m specifically talking about rule #3: "Program in tasks (chores), not threads (cores)."
In a recent post, Robert Chesebrough (Intel) talked about less focus on threads and more focus on tasks. I agree with him. I do believe that decomposing the job to be done into many tasks is the key to a successfully parallelized algorithm.
Several years ago, when I looked for training courses on the subject of parallel programming for shared memory systems I found few courses being offered. Some friends of mine and I did find a very nice course from a 3rd-party vendor on threaded programming. The course mainly focused on "C" and using POSIX threads to explicitly manage thread creation. The course did touch on higher level concepts such implementing a producer consumer using semaphores - but on balance - my recollection of the course was how I had to manage threads as