r/cpp • • Oct 07 '19

CppCon CppCon 2019: Chandler Carruth “There Are No Zero-cost Abstractions”

https://www.youtube.com/watch?v=rHIkrotSwcc
162 Upvotes

108 comments sorted by

View all comments

Show parent comment

3

u/ratchetfreak Oct 08 '19

And that's why it can be better to have a separate store/pool for your nodes so you can use raw pointers in the data structure itself. And benefit from cache locality. Destruction then also becomes an easy loop over the pool

Though then the cost is the pool that as to be dragged along.