~/talk

From Iterators to Ranges — the Upcoming Evolution of the Standard Library

Talkat ACCU 2021 Online · 2021-03-10..03-13· [c-and-cpp, software-architecture]
links:none on file
slides:none on file

Think-cell runs a million+ line codebase using Eric Niebler’s range ideas and demonstrates concrete changes: naive nested transform/filter views make iterators balloon exponentially, so an index-based ranges design keeps iterators two words (range pointer + index) and preserves performance. Adding generators/coroutines lets internal iteration outperform iterator-based concat and avoid double work. Practical results: iterator-based lazy repeat_n is ~50% slower than hand code, internal-iteration versions ~15% slower, and a specialized appender saves ~20% over std::string append.

AI-written summary · about

  1. 0:00Intro
  2. 0:40Ranges in C++20
  3. 1:53Why do I think I know something about ranges? think-cell
  4. 4:36What are Ranges?
  5. 8:18Transform Adaptor (2)
  6. 9:01Transform Adaptor Implementation
  7. 10:14Filter Adaptor Implementation
  8. 13:48More Efficient Range Adaptors: Iterator Safety think-cell
  9. 15:28Again: How does iterator look like of
  10. 17:13Index-Iterator Compatibility
  11. 18:27Super-Efficient Range Adaptors With Indices
  12. 24:34More Flexible Algorithm Returns (3)
  13. 29:11External iteration (2)
  14. 32:08Coroutines (2)
  15. 34:36Internal Iteration often good enough
  16. 39:45Interruptable Generator Ranges (2)
  17. 41:23concat implementation with indices (2)
  18. 43:03concat implementation as generator range
  19. 46:52Format Strings
  20. 49:13Formatting Into Containers (1)
  21. 54:15Fast Formatting Into Containers
  22. 59:37Better reserve
~/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.