performance-review

kcenon 的头像作者 kcenon

提供性能优化指南,用于性能分析、缓存、内存管理和并发。在优化慢代码、修复内存泄漏、提高吞吐量或进行性能审查时使用。

📖 中文导读:提供性能优化指南,用于性能分析、缓存、内存管理和并发。在优化慢代码、修复内存泄漏、提高吞吐量或进行性能审查时使用。 以下正文为该技能的原始 SKILL.md 内容(英文),上方安装命令可直接使用。

name: performance-review description: Provides performance optimization guidelines for profiling, caching, memory management, and concurrency. Use when optimizing slow code, fixing memory leaks, improving throughput, or conducting performance reviews.

Performance Review Skill

When to Use

  • Code performance optimization
  • Memory leak fixes
  • Throughput improvements
  • Performance review requests
  • Bottleneck analysis

Performance Analysis Workflow

Profiling → Identify bottlenecks → Optimize → Verify

Checklist

Algorithm & Data Structures

  • Time complexity analysis (Big-O)
  • Appropriate data structure selection
  • Remove unnecessary operations

Memory

  • Minimize memory allocation
  • Object reuse (pooling)
  • Cache-friendly access patterns

Concurrency

  • Minimize lock contention
  • Leverage async I/O
  • Thread pool optimization

Caching

  • Appropriate cache strategy
  • Cache invalidation policy
  • Cache hit rate monitoring

Reference Documents (Import Syntax)

@reference/performance.md @reference/memory.md @reference/concurrency.md @reference/monitoring.md

Caution

"Premature optimization is the root of all evil" - Donald Knuth

Always confirm bottlenecks through profiling before optimizing.