dotnet-allocation-triage

Installation
SKILL.md

.NET Allocation Triage Workflow

Find allocation hot spots statically, confirm they matter dynamically, fix, then verify — pairing dotnet-inspect (static, IL-precise) with a benchmark or profiler (dynamic, ground truth). This skill is the workflow; for tool capabilities, output modes, shapes, and flags, defer to the version-matched guide:

dnx dotnet-inspect -y -- skill

Workflow

  1. Triage statically. Build Release, then run dotnet-inspect's Performance Triage over the assembly to get a ranked list of pay-dirt allocation sites (member, shape, fix, confidence, in-loop). The cheapest first pass — works on a binary and its dependencies, no profiler needed. See the embedded guide for the exact command and filters.
  2. Confirm it's real. Static triage finds candidates; only a dynamic tool proves a win:
    • Micro: wrap the hot method in a BenchmarkDotNet benchmark with [MemoryDiagnoser]; record allocated bytes before/after.
    • Running app: capture a GC/allocation trace with dotnet-trace collect --profile gc-verbose, or watch System.Runtime GC counters with dotnet-counters monitor, and confirm the member shows up and shrinks.
  3. Fix, then re-triage to confirm the row is gone and re-benchmark to confirm the allocation dropped.

When to use / not use

Installs
1
GitHub Stars
57
First Seen
11 days ago
dotnet-allocation-triage — richlander/dotnet-skills