Plurrrr

Fri 18 Sep 2020

Memory optimizations for Go systems

Despite its growing popularity as a systems language, Go programs are susceptible to severe performance regressions at large scale. In systems with high memory usage, garbage collection (GC) can cause performance regressions by cannibalizing resources from the main program. The goal of this post is to help you understand:

  • How Go GC works at a high level? Why would it impact your system’s performance?
  • What causes GC pressure (more resources spent on GC)?
  • How to determine if GC pressure is the cause of your performance problems?
  • How to measure and profile your program’s heap usage?
  • How to identify which part of the code is the culprit?
  • What are some steps you can take to lower heap usage and GC pressure?

Source: Memory optimizations for Go systems, an article by Nishant Roy.

Editing for cleaner merges

As we add new code to existing files, it feels natural to append – add new functions at the end of the file, new requires at the end of the list of requires, and so on. This approach introduces some friction, and in this post I'll share some pointers for improved editing and git workflow.

Source: Editing for cleaner merges, an article by Christian Johansen.