3 ms·
Unfortunately, the terms "data-oriented design" and "data-oriented programming" refer to two different styles of programming. Data-oriented design is the approa
by gnuvince 4y ago
Unfortunately, the terms "data-oriented design" and "data-oriented programming" refer to two different styles of programming. Data-oriented design is the approach to programming made popular by Mike Acton's CppCon keynote—as you say, it focuses on the layout of objects in memory to make the processing of data take advantage of the underlying hardware.
Data-oriented programming is a style of programming that, as far as I know, originates in the Clojure community. It emphasizes using general data structures (vectors, dictionaries) to store all data and make code more re-usable. It has nothing to do with good cache utilization, pre-fetching, or avoiding branch mispredictions.
It's a shame that two styles of programming which are almost diametrical opposites share such similar names.
From the look of the article, it's discussing data-oriented design, but in Python, and I agree that it's kind of a weird match.
- tvb12 4y agoWait, what? Thanks for pointing this out. I was pretty close to submitting an order with a Data-oriented Programming book in my cart.
- typon 4y agoThere is no book on data oriented design as far as I know. It would be great if someone could take Mike Actons talk and similar talks and condense the ideas into a book filled with real world examples.
- Jtsummers 4y agohttps://www.dataorienteddesign.com/dodmain/ https://www.dataorienteddesign.com/dodmain/ There is this one. It has been posted here a few times. EDIT: I'd meant to link to the updated one: https://www.dataorienteddesign.com/dodbook/ https://www.dataorienteddesign.com/dodbook/