Session
10 Aha! moments exploring the go source code
In this talk I going to share my experience through the reading of the Go compiler/runtime source code. While I was reading the code and preparing talks like "Dissecting Slices, Maps and Channels in Go" or "Understanding the Go Compiler", I had some interesting "Aha!" moments. Thinks that clicked in my head, or given me an interesting insight about how the go programming language work.
In this talk we are going to explore 10 of that aha moments. Some of them is going to provide you better understanding of how the language work, some of them are going to make you more conscious about certain performance implications and some of them, maybe, can inspire you to build something new. But all of them catch my attention, and I think is going to captures yours.
The talk is going to cover in that 10 aha moments the following things:
- How slices are implemented (the underneath shared array between slices and subslices)
- The cooperative nature of the goroutines (As how channels work and how the goroutines park itself and wake up others, or how the scheduler ticks)
- The syntax of go (What the AST can represent and how that derives into what is possible to write in the language)
- Escape analysis + Inlining (How they collaborate to improve the performance)
- The SSA lowering (How most of the compiler is CPU architecture agnostic)
- SSA and tinygo (Tinygo leverage go SSA and LLVM to build microcontrollers binaries)
- The compiler/runtime tandem (How some part of the go syntax simply generates runtime calls)
- The main function is not the entry point (The runtime bootstrap is the entry point, your main function is called later)
- The Memory Allocator (What is it, and it works so efficiently)
- What makes the GC ticks (The memory allocations + the sysmon)
Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.
Jump to top