Tips on Compiler Optimization

Useful tips and tricks for programming in Go.

Compiler Optimizations

You can pass specific compiler flags to see what optimizations are being applied as well as how some aspects of memory management. This is an advanced feature, mainly for people who want to understand some of the compiler optimizations in place.

Let’s take the following code example from an earlier chapter:

Get hands-on with 1200+ tech skills courses.