Performance Profiling
Launch profiler subagent for deep performance analysis.
Workflow
- •Identify target - specific code, function, or general slowness
- •Launch profiler subagent using Task tool with
subagent_type: profiler - •Report findings with evidence and recommendations
Profiler Subagent Prompt
code
Analyze performance for: [target] Context: [what feels slow, user observations] 1. Measure baseline first (don't guess) 2. Identify hot paths from profiling data 3. Analyze: complexity, allocations, I/O, concurrency, caching 4. Recommend optimizations with expected impact 5. Persist findings to ai/review/ with before/after measurements Evidence-based only. No assumptions.
Output Format
code
## Performance Analysis Target: [what was analyzed] Baseline: [measured performance] ## Findings 1. [Bottleneck] - [measurement] - [impact] 2. ... ## Recommendations | Fix | Expected Impact | Effort | |-----|-----------------|--------| | ... | ... | ... | ## Next Steps 1. [Specific action] 2. [Specific action]