# Bench Fast

> Run a benchmark with minimal iterations to generate assembly code via BenchmarkDotNet's DisassemblyDiagnoser. Use to generate one big assembly code file per benchmark.

- Skill: `bitfaster/bench-fast` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add bitfaster/bench-fast`
- Raw SKILL.md: https://api.skillmd.com/api/skills/bitfaster/bench-fast/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: bitfaster (https://skillmd.com/u/bitfaster)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/bitfaster/bench-fast

---


## Usage

```
/bench-fast <BenchmarkName> [<Runtimes>]
```

## Arguments

- `$ARGUMENTS` - The name of the benchmark class to run (e.g., `LruJustGetOrAdd`, `LfuJustGetOrAdd`, `SketchIncrement`), optionally followed by a list of one or more runtimes (e.g., `net48`, `net9.0` or `net48 net9.0`)

## Instructions

Run the specified benchmark from BitFaster.Caching.Benchmarks with minimal iterations using BenchmarkDotNet's command line.

Parse the arguments: the first argument is the benchmark name, and the optional second argument is the list of runtimes.

If a runtime arg is specified, execute:

```bash
dotnet run -c Release --project BitFaster.Caching.Benchmarks --framework net9.0 -- --runtimes <Runtimes> --filter "<BenchmarkName>" -j short --warmupCount 3 --iterationCount 5 -d --disasmDepth 5
```

If no runtime is specified, simply omit that command line arg:

```bash
dotnet run -c Release --project BitFaster.Caching.Benchmarks --framework net9.0 -- --filter "<BenchmarkName>" -j short --warmupCount 3 --iterationCount 5 -d --disasmDepth 5
```

The `--warmupCount 3 --iterationCount 5` options reduce warmup and iteration counts for faster execution while still executing the code enough times to JIT optimized code.

