Enabling data-oriented design

Joakim via Digitalmars-d digitalmars-d at puremagic.com
Sun Dec 18 08:06:38 PST 2016


On Sunday, 18 December 2016 at 14:58:53 UTC, Stefan Koch wrote:
> On Sunday, 18 December 2016 at 14:22:29 UTC, Joakim wrote:
>> I was looking at the most popular videos from CppCon and the 
>> second-most popular from the last three years is the one on 
>> data-oriented design:
>>
>> https://youtube.com/watch?v=1OEu9C51K2A

Hmm, looks like I pasted a link to the wrong CppCon video, here's 
the one on data-oriented design:

https://youtube.com/watch?v=rX0ItVEVjHc

>> The wikipedia page has a summary, basically focusing on cache 
>> effects more, with links to articles:
>>
>> https://en.wikipedia.org/wiki/Data-oriented_design
>>
>> Obviously the effects of cache are well-known here and other 
>> places that focus on performance, but maybe there's more we 
>> can do to enable this paradigm in the language.
>
> I would not be too sure that this is something the language can 
> help with.
> It is more a question of the right tools.
> And In theory features like mixins, introspection and property 
> functions should make it possible to profile your memory-access 
> patterns in a nice way.

One of the arguments for DOD in the WP link and elsewhere is that 
typically OOP-heavy code, as you see in much game programming, is 
not conducive to this type of design.  To the extent someone is 
using D's OOP features heavily, they will run into this too.  I 
would imagine ranges are very conducive to the DOD approach, so 
it's not like D doesn't support it.  The question is whether we 
can support this design trend more.


More information about the Digitalmars-d mailing list