standards-go-performance

Profile Go services with pprof and trace to resolve performance bottlenecks.

2|Updated Apr 10, 2024
One-click install
npx skills add https://github.com/gdurandvadas/dotfiles --skill standards-go-performance
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: standards-go-performance
Source: https://github.com/gdurandvadas/dotfiles/tree/main/config/opencode/skills/standards-go-performance
Command: npx skills add https://github.com/gdurandvadas/dotfiles --skill standards-go-performance

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Go performance issues are often hidden in allocations, GC behavior, and concurrency bottlenecks. This skill provides a structured approach to profiling, diagnosing, and mitigating performance regressions in Go services, enabling data-driven optimizations and safer releases.

Core Features & Use Cases

  • pprof/trace workflows for CPU/heap analysis and runtime profiling.
  • Allocation control patterns and GC tuning guardrails.
  • Runtime metrics and observability patterns to monitor health and efficiency.
  • Pattern-driven guidance for escape analysis, inlining, and concurrency improvements.

Quick Start

Run a CPU profile against a representative Go service and apply the findings to optimize hot paths and reduce allocations.

Frequently Asked Questions about standards-go-performance

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I identify and resolve Go performance bottlenecks in production services?

Identify and resolve Go performance bottlenecks through structured profiling workflows using pprof and trace. This skill diagnoses CPU-bound workloads, memory pressure, and concurrency scenarios, applying documented patterns for allocation reduction and escape analysis to optimize hot paths.

What's the best way to reduce memory allocations and tune GC behavior in Go?

Reduce memory allocations and tune GC behavior using allocation control patterns and GC tuning guardrails. The skill provides pattern-driven guidance for escape analysis and inlining, ensuring data-driven optimizations that mitigate memory pressure safely in production Go services.

Can I use pprof and trace workflows for runtime profiling on live production Go services?

pprof and trace workflows apply to production Go services with safe production guardrails. The skill leverages runtime/metrics and observability patterns to monitor health and efficiency, ensuring profiling-driven performance tuning does not disrupt live environments.

Why does my Go service have hidden performance regressions after deployment?

Go performance issues are often hidden in allocations, GC behavior, and concurrency bottlenecks. This skill provides a structured approach to profiling and diagnosing these regressions, enabling data-driven optimizations and safer releases through runtime metrics and pattern-driven analysis.

How do I apply Profile-Guided Optimization (PGO) to optimize hot paths in Go?

Apply Profile-Guided Optimization (PGO) by running a CPU profile against a representative Go service. The skill guides you to analyze the findings, apply escape analysis, reduce allocations, and implement concurrency improvements to optimize hot paths effectively.

Does this approach support concurrency bottleneck analysis in performance-sensitive Go code?

Concurrency bottleneck analysis is fully supported for performance-sensitive Go code. The skill covers concurrency scenarios alongside CPU-bound workloads, applying structured profiling workflows and runtime metrics to diagnose and mitigate performance regressions comprehensively.