Performance
GC: free-recall review
Retrieval beats re-reading. For each prompt, say or write a full answer from memory before you open the model answer — the effort of recall is what makes the material stick.
Reconstruct the unit’s core mechanisms — live set vs RSS, the generational hypothesis, GOMEMLIMIT, tri-color marking, and the fix-priority ladder — without looking back at the lessons.
- 01Why does allocation rate drive GC-driven tail latency more than total heap size?
- 02State the generational hypothesis and give one counterexample collector.
- 03What is the difference between RSS and the live set, and why does it matter for tuning?
- 04Explain the tri-color invariant and what the write barrier does to preserve it.
- 05What does GOMEMLIMIT do, and why is it the first knob for a containerised Go service?
- 06List the GC-pressure fix levers in priority order, highest leverage first.
If you could reconstruct each answer from memory, you hold the unit’s spine: allocation rate sets frequency, live set sets cost, the generational hypothesis explains most collectors (and Go’s deliberate exception), the tri-color invariant plus write barriers make concurrent marking correct, GOMEMLIMIT defends a container’s bound, and the fix ladder always starts with eliminating allocations — not tuning.