Perf profile

From TraftG/opencode-game-studio · View interactive version

Perf profile is an AI agent skill from the GitHub repository TraftG/opencode-game-studio. Structured performance profiling workflow. Identifies bottlenecks, measures against budgets, and generates optimization recommendations with priority rankings.

How to use this skill

Skill file

When this skill is invoked:

  1. Determine scope from the argument:
  1. Read performance budgets — Check for existing performance targets in design docs or OPENCODE.md:
  1. Analyze the codebase for common performance issues:

CPU Profiling Targets:

Memory Profiling Targets:

Rendering Targets (if applicable):

I/O Targets:

  1. Generate the profiling report:

```markdown

## Performance Profile: [System or Full]

Generated: [Date]

### Performance Budgets

| Metric | Budget | Estimated Current | Status |

|--------|--------|-------------------|--------|

| Frame time | [16.67ms] | [estimate] | [OK/WARNING/OVER] |

| Memory | [target] | [estimate] | [OK/WARNING/OVER] |

| Load time | [target] | [estimate] | [OK/WARNING/OVER] |

| Draw calls | [target] | [estimate] | [OK/WARNING/OVER] |

### Hotspots Identified

| # | Location | Issue | Estimated Impact | Fix Effort |

|---|----------|-------|------------------|------------|

| 1 | [file:line] | [description] | [High/Med/Low] | [S/M/L] |

| 2 | [file:line] | [description] | [High/Med/Low] | [S/M/L] |

### Optimization Recommendations (Priority Order)

1. [Title] — [Description of the optimization]

### Quick Wins (< 1 hour each)

### Requires Investigation

```

  1. Output the report with a summary: top 3 hotspots, estimated headroom vs budget, and recommended next action.

Rules

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.