Ultimate Go with Miki Tebeka

When: February 19th - 22nd, 2024

Schedule: 4 Days/ 4 Hours, from 8am to 12pm EST (GTM - 5)

Where: Online - Zoom Meeting

Description: The workshop is composed of four 4-hour sessions. It is aimed toward developers who have experience with Go and would like to understand how to write more efficient code and understand data semantics and concurrency patterns. We’ll cover many coding best practices that help write precise code.

What a student is expected to learn:


Day 1: Memory & Data Semantics

Programming vs engineering:

  • Value semantics
  • Pointer semantics and Ownership rules

Stack vs heap allocations and how they affect your code:

  • Detecting and understanding escape analysis

How the garbage collector (GC) works and its effect on performance:

  • Common causes for memory leaks

Writing CPU cache-friendly code:

Working with slices in memory efficient way:

  • Range loop semantics

Day 2: Data Oriented Design

Data-oriented design:

  • Choosing value vs pointer semantics
  • Built-in types
  • User-defined types

Polymorphism with interfaces:

  • Modeling interfaces
  • How interfaces are implemented understanding cost

Using embedding: Difference from traditional OO

Using generics

  • Generics functions
  • Generic data structures

Method set rules


Day 3: Concurrency

The OS scheduler:

  • Design and tradeoffs
  • How they affect you

The Go schedule:

CPU vs I/O bound job:s

Synchronization and orchestration:

  • Understanding channels
  • Using sync and sync/atomic
  • Concurrency patterns
  • Wait for results
  • Fan out
  • Polling

Day 4: Performance Optimization

Before you start optimizing:

CPU Profiling:

  • Writing benchmarks
  • Using the profiler
  • Using the execution traces

Memory profiling:s

  • Benchmarking memory
  • Using the GC tracer
  • Using the execution tracer

Prerequisites

You should have experience writing Go code. You should have the following installed on your machine:

  • Go SDK
  • IDE such as VSCode with the Go extension or Goland
  • Git
  • graphviz