Dmitry Vyukov — Go scheduler: Implementing language with lightweight concurrency
Hydra2 HN recommenders · recommended in 2 months, 2020–2026
talk · advanced · evergreen · 2020–2026 on HN
Go runtime contributor Dmitry Vyukov looks inside the Go scheduler, explaining how goroutines and channels are implemented. He covers the main scheduler components and overall operation, then goes into details such as preemption and stacks.
Recommended as a good watch on how Go's M:N:P scheduler works and why it was designed that way compared with alternative schemes.
Up next
10 mo on HNBrian Beckman: Don't fear the Monad
jasonofthel33t
9 HN recommender · 2012–2024
11 mo on HNCppCon 2015: Andrei Alexandrescu “std::allocator...”
CppCon
7 HN recommender · 2017–2025
12 mo on HNLexical Scanning in Go - Rob Pike
GoogleFOSSSydney
13 HN recommender · 2012–2025
10 mo on HNCppCon 2017: Matt Kulukundis “Designing a Fast, Efficient, Cache-friendly Hash Table, Step by Step”
CppCon
9 HN recommender · 2018–2026
9 mo on HNRustConf 2018 - Closing Keynote - Using Rust For Game Development by Catherine West
Rust Programming Language
9 HN recommender · 2018–2023
10 mo on HNCppCon 2016: Jason Turner “Rich Code for Tiny Computers: A Simple Commodore 64 Game in C++17”
CppCon
13 HN recommender · 2016–2024
9 mo on HNIdeas about a new programming language for games.
Jonathan Blow
7 HN recommender · 2014–2025
9 mo on HNCppCon 2014: Mike Acton "Data-Oriented Design and C++"
CppCon
9 HN recommender · 2015–2026
9 mo on HNHow I program C
Eskil Steenberg
8 HN recommender · 2017–2025
9 mo on HNGoogle I/O 2012 - Go Concurrency Patterns
Google for Developers
9 HN recommender · 2012–2025
7 mo on HNCppCon 2015: Kate Gregory “Stop Teaching C"
CppCon
7 HN recommender · 2016–2025
7 mo on HNZig: A programming language designed for robustness, optimality, and clarity – Andrew Kelley
Recurse Center
6 HN recommender · 2018–2024
3 comments from Hacker News
▶ this video - Dmitry Vyukov — Go scheduler: Implementing language with lightweight concurrency This one notably also explains the design considerations for golangs M:N:P in comparison to other schemes and which specific challenges it tries to address.
I guess that's because they are "intros," and often multi-core event loops are implemented by the language runtime or some threadpool library. This is a good watch: Dmitry Vyukov — Go scheduler: Implementing language with lightweight concurrency (Oct 14, 2019) ▶ this video
Go depends on the fact that it can track all pointers, and when it needs to resize stacks, it can update them. Previous versions of Go used segmented stacks, which are theoretically possible, if Zig really wanted (would need compiler support), but they have nasty performance side-effects, see ▶ this video