Re: [Algorithms] General purpose task parallel threading approach
Brought to you by:
vexxed72
|
From: Gregory J. <gj...@da...> - 2009-04-13 20:01:11
|
That's what I took from Jon's comments (and Jon can clear this up if incorrect): that when you write a piece of code, it has inherent static data dependencies. For example, a piece of code that is written to post-process the results of, say, narrow-phase collision detection, isn't suddenly going to depend, without changing the code, on, say, the results of a pathfinding iteration. Since you have to change the code, and that act is performed in a static manner (at code authoring time) then that piece of code is known a priori to depend on a particular set of data inputs, and you can declare those dependencies in such a way (for example, using the metadata described) that a dynamic task scheduler can intelligently schedule that piece of code to run when its data is ready. Greg From: Mat Noguchi [mailto:mat...@bu...] Sent: Monday, April 13, 2009 10:43 AM To: Game Development Algorithms Subject: Re: [Algorithms] General purpose task parallel threading approach Of course it doesn't work with a C++-vtable-dispatch mechanism; that does not allow you to separate the behavior of the task from the structure (i.e., dependencies) of the task. What Jon is talking about (I presume) is that tasks are not just vtables or function pointers; they have information associated with them that allows for higher order reasoning without running them. MSN |