What problem does it solve? Go developers often guess at performance bottlenecks instead of measuring them, leading to wasted optimization effort and regressions. This Skill provides concrete patterns for benchmarking, CPU/memory/goroutine profiling with pprof, and common optimization techniques so performance work is driven by data. ## Core Features & Use Cases - Benchmark Authoring: Write Go benchmarks with testing.B, allocation tracking via b.ReportAllocs(), and run them with go test -bench flags including -benchmem and -count. - pprof Profiling: Collect CPU, heap, and goroutine profiles from a running server via net/http/pprof or from test runs with -cpuprofile and -memprofile flags. - Optimization Patterns: Apply pre-allocation of slices, sync.Pool buffer reuse, and strings.Builder concatenation to reduce allocations, plus caching strategies with sync.Map, LRU, or Redis. - Use Case: A Go API endpoint is slow under load. Use this Skill to capture a 30-second CPU profile, identify the hot function, write a benchmark, apply pre-allocation and pooling, then verify the improvement with before/after numbers. ## Quick Start Ask the agent to profile the slow endpoint in my Go service and write a benchmark comparing performance before and after optimization.