~/talk

“How to Choose the Right Standard Library Container, and Why You Should Want Some More”

Talkat CppCon 2019 · 2019-09-15..09-20· [software-architecture]
links:none on file
slides:none on file

Three concrete case studies compare list, vector, deque, a homegrown shifty vector, and colony on real tests (10k widgets, queue ≈10). Visual Studio 2017 profiling shows list is slow due to allocations; vector cuts time ~3.5× and memory ~5× with reserve; deque halves time but raises memory ~3×; shifty vector is ~2.5× faster than deque and ~4.5× faster than vector with vector-like memory; colony yields ~5× speedup and slightly lower footprint. Recycling vectors (move+clear into a pool) fixes capacity thrash and speeds one simulation ~12× (435 → 35 min), measured with Windows peak-commit and a profiler.

AI-written summary · about

  1. 0:00Introduction
  2. 1:00A Tale of Letters
  3. 5:05Containers
  4. 11:57How does it work
  5. 13:33Deck
  6. 15:29Shifty Vector
  7. 20:41Fixed Capacity
  8. 27:09The Colony
  9. 28:42The Container
  10. 29:51Where were we
  11. 32:40What happens in a vector
  12. 36:22A simple approach
  13. 38:42A real world example
  14. 39:25Dont make assumptions
  15. 43:00How to measure memory
  16. 43:54Did you try to use allocators
  17. 44:53Are there good quality implementations
  18. 46:07Associative containers
  19. 47:10Tools to investigate containers
  20. 48:34The way it would work
  21. 50:11Timesteps
  22. 53:14Memory
  23. 54:10ShiftyVector
  24. 55:26Vector Size
  25. 56:13Element Size
  26. 58:02Block Size
  27. 59:35STD
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.