~/talk

A <chrono> Tutorial

slides:none on file

Chrono is a type-safe C++ time library that wraps integers (seconds are a long long) and performs conversions at compile time with zero runtime overhead; it reports a surprising range of ±292 billion years for seconds, allows implicit lossless conversions but requires duration_cast for lossy ones, and forbids implicit integer↔duration conversions to catch bugs. It provides customizable durations via template ratios, time_point/clock types (system_clock vs steady_clock), and requires .count() to extract raw values for legacy I/O.

AI-written summary · about

  1. 0:00Introduction and motivation
  2. 1:25Why use Chrono library
  3. 2:50Time durations basics
  4. 7:27Duration arithmetic
  5. 9:14Performance overhead
  6. 12:05Migrating time units
  7. 17:26Manual conversions
  8. 21:20Lossy conversions
  9. 23:51More time units
  10. 25:36Custom representations
  11. 29:11Custom durations
  12. 33:03Duration template details
  13. 38:20Time points explained
  14. 41:37Time point arithmetic
  15. 44:24Time point conversions
  16. 46:35Clocks in Chrono
  17. 49:03System vs steady clocks
  18. 50:06Timing functions
  19. 51:50Custom durations example
  20. 52:54System clock time points
  21. 53:36Summary and Q&A
~/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.