# dotnet-inspect-performance

Ranks .NET assembly members by call-graph leverage and triages IL allocation patterns. Useful for prioritizing library optimizations before running benchmarks.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 411 installs · ★ 156
- Author: richlander
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/richlander/dotnet-inspect/tree/HEAD/skills/performance/SKILL.md
- Updated: 2026-10-25
- HTML: https://affpapa.org/en/nevibecode/skills/dotnet-inspect-performance

## What it does

The skill analyzes compiled .NET assemblies using `dnx dotnet-inspect`. Its `Top Leverage` section ranks methods by direct callers and transitive entry points. This highlights high-impact routines across an entire library or within a specific type before you modify source code.

Performance triage scans intermediate language for specific allocation shapes under `@Performance`. It flags boxed value types, capturing delegates, string builds, and synchronous calls inside async methods. The tool focuses on structural IL costs rather than JIT optimizations like devirtualization or null-check folding.

Treating high-priority findings as mandatory rewrites without allocation traces will waste effort; confirm candidate impact with benchmarks first. Because static inspection cannot determine runtime iteration counts or sequence sizes, scan helpers carry low confidence by design.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add richlander/dotnet-inspect --skill dotnet-inspect-performance -a claude-code
```
```bash
npx skills add richlander/dotnet-inspect --skill performance -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/performance/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/performance/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add richlander/dotnet-inspect --skill performance -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/performance/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add richlander/dotnet-inspect --skill performance -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/performance/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install richlander/dotnet-inspect performance
```

2. **Manually: put the files in place**
- File: `.github/skills/performance/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add richlander/dotnet-inspect --skill performance -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/richlander/dotnet-inspect --path skills/performance
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/performance/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add richlander/dotnet-inspect --skill performance -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/richlander/dotnet-inspect/tree/HEAD/skills/performance/SKILL.md

## When to use it
- rank .NET assembly members by call-graph reach
- spot boxed value types and generic object boxing in IL
- identify capturing delegates and loop-allocated collections
- detect synchronous calls within async state machines

## Example prompts
- Inspect MyLib.dll with dotnet-inspect and show Top Leverage members.
- Run dotnet-inspect on MyLib.dll targeting capturing delegates and boxing with high priority.
- Check MyType in MyLib.dll for synchronous calls inside async methods.

## Similar
- [analyzing-dotnet-performance](https://affpapa.org/en/nevibecode/skills/analyzing-dotnet-performance.md) — skill · 4900 installs
- [type-design-performance](https://affpapa.org/en/nevibecode/skills/type-design-performance.md) — skill · 655 installs
- [golang-performance](https://affpapa.org/en/nevibecode/skills/golang-performance.md) — skill · 41900 installs
- [dotnet-design-pattern-review](https://affpapa.org/en/nevibecode/skills/dotnet-design-pattern-review.md) — skill · 11609 installs
- [eval-performance](https://affpapa.org/en/nevibecode/skills/eval-performance.md) — skill · 3400 installs
- [dotnet-architect](https://affpapa.org/en/nevibecode/skills/dotnet-architect.md) — skill · 351 installs

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
