CppCon 2016: Matthew Bentley “Colonies, performance and why you should care"





The interactive transcript could not be loaded.


Rating is available when the video has been rented.
This feature is not available right now. Please try again later.
Published on Sep 29, 2016


Presentation Slides, PDFs, Source Code and other presenter materials are available at: https://github.com/cppcon/cppcon2016

In game development and many other high-performance, highly-modular development architectures, maintaining valid references to container elements regardless of erasure and insertion is often crucial. While there are many workarounds for this, typically using std::vector with various methods to avoid invalidation, to date there exist no generalized solutions to the problem which also provide strong cache performance.

plf::colony, a proposed unordered container class from the SG14 working group, is one attempt to remedy this situation: it provides fast insertion, erasure and iteration performance while maintaining pointer stability to non-erased elements, which is unaffected by both insertion and erasure.

In this talk we’ll explore both the structure and comparative performance of plf::colony, contrasting it with other standard library containers and their potential modifications, showing how it can outperform many typical alternatives where large amounts of insertions and erasures are concerned. This will include details on:

The “jump-counting” skipfield pattern, a new numeric pattern which has better performance than its boolean counterpart.

plf::stack, a replacement for std::stack with stronger stack performance than other standard library containers.

The chained-group allocation pattern, common to both containers.

If you’re not interested in new containers, you may still pick up a few concepts to help you with improving your own implementations and high-performance C++ code. If you are interested in better containers, or better container usage, you should definitely attend this talk.

Matthew Bentley
Computer Engineer
Matt Bentley was born in 1978 and never recovered from the experience. He started programming in 1986, completing a BSc Computer Science 1999, before spending three years working for a legal publishing firm, getting chronic fatigue syndrone, quitting, building a music studio, recovering, getting interested in programming again, building a game engine, and stumbling across some generalized solutions to some old problems.

Videos Filmed & Edited by Bash Films: http://www.BashFilms.com


When autoplay is enabled, a suggested video will automatically play next.

Up next

to add this to Watch Later

Add to

Loading playlists...