Systems Engineer
Go Garbage Collector – Built from Scratch
GoSystems ProgrammingMemory ManagementData Structures
About
A mark-and-sweep garbage collector implemented in Go from scratch. Built to deeply understand how memory management works under the hood — heap allocation, object graphs, reachability analysis, and GC pause times.
What I Built
Implemented mark-and-sweep in two phases: DFS traversal to mark live objects, then sweep to reclaim unreachable memory
Learned how GC pause times emerge and why generational GC exists as an optimization
Deep understanding of heap layout, pointer chasing, and why Go uses a tricolor marking algorithm in production
Explore the project