game-perf-profiling
БесплатноБез исполняемых скриптовНе проверенUse when a game must hit a frame-time or memory budget before a milestone or platform cert, or a change needs a performance regression check. Profiles with…
от testland★ 18 звёзд на GitHubОб этом скилле
game-perf-profiling
Overview
Game performance QA verifies that a build meets its declared budgets across every target SKU before milestone sign-off or platform-cert submission. The performance category (category 4 in the platform-cert-overview-reference test-category taxonomy) covers frame-time, memory, GPU, thermal, and battery axes. This skill covers the two dominant engine stacks: Unity and Unreal Engine.
Frame-time budget anchors (from platform-cert-overview-reference):
| Target frame rate | Frame-time budget |
|---|---|
| 60 fps | 16.67 ms per frame |
| 30 fps | 33.33 ms per frame |
Measuring averages is an anti-pattern: spikes hide in averages and cause cert failures. Measure p99 (99th-percentile frame time) and sustained-window maximums.
Step 1: Unity - Capture with the Profiler
Open the Profiler via Window > Analysis > Profiler (Ctrl+7) and enable
the CPU Usage, GPU Usage, and Memory modules for a frame-time pass. Save the
capture as a .data file (Profiler toolbar > Save) and retain it alongside
any Profile Analyzer .pdata export - the .pdata file does not embed the
original profile frames. Module-by-module capture detail, GPU-module platform
constraints, and Profile Analyzer setup are in
references/unity-profiler.md.
Step 2: Unity - Analyze with Profile Analyzer
Profile Analyzer compares two captures side by side, which the standard Profiler cannot. Open it via Window > Analysis > Profile Analyzer, then run the regression check:
- Load the baseline
.datafile as the left dataset. - Load the candidate
.datafile as the right dataset. - Compare median and p99 frame times per marker against the budget.
- Flag any marker whose p99 exceeds the per-frame budget allocation.
Step 3: Unity - Automated regression with Performance Testing package
Add "com.unity.test-framework.performance": "3.0.3" to Packages/manifest.json
and reference Unity.PerformanceTesting in your assembly definition
(docs.unity3d.com/Packages/[email protected]/manual/index.html).
Measure.Method (Edit Mode or Play Mode)
[Test, Performance]
public void PathfindingCost_UnderBudget()
{
Measure.Method(() => pathfinder.FindPath(start, goal))
.WarmupCount(5)
.MeasurementCount(20)
.IterationsPerMeasurement(10)
.Run();
}
WarmupCount(n): executes the method n times before recording to remove initialization overhead.MeasurementCount(n): number of samples recorded; default is 7; 20+ improves stability.IterationsPerMeasurement(n): repeats the code within each measurement to extend execution time above the 1 ms sensitivity floor.
Measure.Frames (Play Mode)
[UnityTest, Performance]
public IEnumerator CombatScene_FrameTime_UnderBudget()
{
yield return Measure.Frames()
.WarmupCount(5)
.MeasurementCount(60)
.Run();
}
Target standard deviation below 5%; avoid measurements under 1 ms due to environmental sensitivity.
Decorate tests [Test, Performance] for Edit Mode or [UnityTest, Performance]
for Play Mode coroutines. View results via Window > Analysis > Performance
Test Report.
GC-spike detection
Enable the ProfilerMarkers method on Measure.Method to target
GC.Alloc markers specifically:
Measure.Method(() => SpawnWave())
.ProfilerMarkers("GC.Alloc")
.MeasurementCount(20)
.Run();
A passing frame should produce 0 bytes of GC allocation in hot gameplay paths. Any non-zero sample is a regression candidate.
Disable VSync in Project Settings and remove cameras not needed for the measurement to keep results consistent between runs.
Step 4: Unreal - Stat commands for first-pass triage
Unreal Engine stat commands are entered into the PIE console while the game runs (dev.epicgames.com/documentation/en-us/unreal-engine/stat-commands-in-unreal-engine):
| Command | Shows |
|---|---|
stat fps |
Frames per second counter |
stat unit |
Frame, Game thread, Draw (render thread), GPU, RHIT, and DynRes times; recommended starting point |
stat gpu |
GPU statistics for the frame |
stat scenerendering |
General rendering statistics; entry point for rendering bottleneck triage |
stat game |
How long the various gameplay ticks are taking |
stat memory |
Memory usage by subsystem |
stat unit is the first command to run on any new build: it identifies
whether the bottleneck is game-thread, render-thread, or GPU, and measures
how long the video card takes to render the scene. Run in a non-debug build
for accurate results.
Step 5: Unreal - Deep analysis with Unreal Insights
When stat triage is not enough, capture a full trace with Unreal Insights.
Launch it from th
Установить game-perf-profiling в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл game-perf-profiling?
Use when a game must hit a frame-time or memory budget before a milestone or platform cert, or a change needs a performance regression check. Profiles with Unity Profiler and Performance Testing or Unreal Insights, sets 16.6 ms and 33.3 ms budgets, adds CI perf tests and reports per SKU.
Как установить скилл game-perf-profiling?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл game-perf-profiling запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
ci-review
The scan that the plugin's GitHub Action runs.
от Anthropicazure-static-web-apps
Helps create, configure, and deploy Azure Static Web Apps using the SWA CLI. Use when deploying static sites to Azure, setting up SWA local development…
от GitHubai-ready
Make any repo AI-ready — analyzes your codebase and generates AGENTS.md, copilot-instructions.md, CI workflows, issue templates, and more. Mines your PR…
от GitHubaws-cdk-python-setup
Setup and initialization guide for developing AWS CDK (Cloud Development Kit) applications in Python. This skill enables users to configure environment…
от GitHub