go-performance

Installation
SKILL.md

Go Performance Patterns

Available Scripts

  • scripts/bench-compare.sh — Runs Go benchmarks N times with optional baseline comparison via benchstat. Supports saving results for future comparison. Run bash scripts/bench-compare.sh --help for options.

Performance-specific guidelines apply only to the hot path. Don't prematurely optimize—focus these patterns where they matter most.


Prefer strconv over fmt

When converting primitives to/from strings, strconv is faster than fmt:

s := strconv.Itoa(rand.Int()) // ~2x faster than fmt.Sprint()
Related skills

More from cxuu/golang-skills

Installs
563
GitHub Stars
91
First Seen
Jan 27, 2026