HackerTubewatch
Surprise me
Frame from CppCon 2018: G. Nishanov “Nano-coroutines to the Rescue! (Using Coroutines TS, of Course)” Plays via YouTube's privacy-enhanced embed

CppCon 2018: G. Nishanov “Nano-coroutines to the Rescue! (Using Coroutines TS, of Course)”

48 videos recommended on HN
YouTube
Cited on HN 3 times, 2018–2021, never outright recommended score 0
Years with an HN recommendation, 2007–2026

Cited as a deep dive on coroutines for cache misses and on running huge numbers of coroutines without heap allocation.

Gor Nishanov's CppCon 2018 talk on using tiny C++ coroutines to hide memory latency, interleaving useful work while prefetches bring cache lines in from main memory.

“also see this video that goes in depth how to have billions of coroutines with C++” (HN, 2019)

3 citations · Talks · advanced

3 Hacker News comments

From the HN archive; up to 20 kept per video, favoring different commenters. Recommendations first.

@akubera Nov 2018 Cites it
on HN thread Exploiting Coroutines to Attack the “Killer Nanoseconds” [pdf]
Gor Nishanov, one of the authors, talks about this in his CppCon2018 talk [this video] (jump to ~12:33 to skip background). It amounts to using CPU prefetch instructions with C++ coroutines to simulate hyperthreading in software by scheduling instructions around cache misses (but is potentially better than hyperthreads because it's not limited to 2/core)
Coroutines with prefetch to hide cache misses.
@je42 Aug 2019 Cites it
on HN thread How Rust optimizes async/await
> In C++, technically every initialization of a sub-coroutine starts defaults to being a new heap allocation. I don't want to spread FUD: my understanding is that the vast majority of these are optimized out by the compiler. But one downside of this approach is that you could change your code and accidentally disable one of these optimizations. I don't think this is correct. C++ 20 allows a lot of choices to implement it without forcing a heap allocation. see [link] also see this video that goes in depth how to have billions of coroutines with C++: [this video]
Deep dive on running billions of C++ coroutines without heap allocation.
@BenFrantzDale Feb 2021 Cites it
on HN thread My tutorial and take on C++20 coroutines
Read more
It's a big deal because, while it has some downsides, being stalkless means they can have next to no overhead, meaning it can be performant to use coroutines to write asynchronous code for even very fast operations. The example given [this video] is that you can launch multiple coroutines to issue prefetch instructions and process the fetched data, so you can have clean code that issues multiple prefetches and process the results. Whereas in Python (don't get me wrong, I love Python) you might use a generator to "asynchronize" slow operations like requesting and processing data from remote servers, C++ coroutines can be fast enough to asynchronously process "slow" operations like requesting data from main memory.
Example of coroutines issuing prefetches around memory latency.

Video list and Hacker News comment labels from HackerTube (prompted by @karpathy), released under ODC-By 1.0, built on the open-index/hacker-news archive. Hacker News data is provided by Y Combinator; comments remain the work of their authors. Video titles, channel names and thumbnails belong to their creators and are shown via YouTube. HackerTube Watch is an unofficial edition. Data export of 2026-10-31.

Keyboard shortcuts

/
Search
j k
Next / previous video
r
Surprise me
l
Like (video page)
w
Watch later (video page)
?
This help
Esc
Close