Benchmark: the agent tool path on Windows

A persistent MCP connection against a fresh PowerShell per call - 20 paired samples per phase, exact output parity.

Benchmark: the agent tool path on Windows#

When an agent reads a file or searches a workspace, the interesting cost is not disk I/O - it is the tool path: everything between the model's decision and the bytes coming back. This benchmark measures that path for venira-mcp against the obvious alternative: letting the agent run shell commands and parse the output.

Setup#

Measured 2026-11-07 (Asia/Bangkok) on Windows 11 build 26200, Intel Core i5-1035G1 (8 logical processors, 11.8 GiB RAM), Node v24.20.0, PowerShell 5.1. Venira 1.15.1 for the live Codex comparison and 1.17.0 for the component benchmark.

Method: twenty paired samples per phase, with each pair alternating call order. Venira calls ran over the persistent MCP connection already open in the Codex session; each native exec_command call launched a fresh PowerShell process. The cold phase cleared the relevant in-process cache before each sample, the warm phase primed and reused it. Windows filesystem cache stayed warm in both phases. Both workloads were checked for exact output parity on every pair.

Live comparison against Codex exec_command#

WorkloadPhaseVenira p50 / p95exec_command p50 / p95Ratio by p50Parity
Read first lines of 8 files in one batchCache miss53.5 / 72 ms962 / 1,121 ms17.98x20/20
Read first lines of 8 files in one batchWarm39 / 60 ms1,103.5 / 1,549 ms28.29x20/20
Search workspace (49 hits)Cache miss118.5 / 188 ms1,034.5 / 1,507 ms8.73x20/20
Search workspace (49 hits)Warm34.5 / 152 ms1,018 / 1,383 ms29.51x20/20

The read comparison compared normalized file text for eight named files; the search comparison compared exact sorted file / line-number pairs. Zero mismatches across all 40 pairs in both workloads.

The pattern is consistent: a fresh PowerShell process costs roughly a second before any work happens, while the persistent connection does the same work in tens of milliseconds - and batching eight reads into one call removes seven round trips on top.

Component benchmark#

Separately, npm run bench:tools -- --runs=100 (100 samples per phase) compared individual tool calls through a persistent local MCP stdio client with native PowerShell operations measured inside one PowerShell process - so native startup cost is excluded and the comparison isolates the tool work itself:

WorkloadPhaseMCP end-to-end p50PowerShell p50
Read 25 lines from package.jsonCache miss4.89 ms1.57 ms
Read batch of 3 filesWarm2.31 ms3.61 ms
List lib/Cache miss1.97 ms3.76 ms
Literal search in one fileWarm0.66 ms41.35 ms

This one is more honest about the trade-off: for uncached single reads and metadata, plain PowerShell is faster - the MCP layer adds a few milliseconds, which is the price of the audit trail, the path guard and the stable envelope. For warm reads, listings and especially search, venira-mcp wins even without the process-startup handicap, because the in-process cache holds results that a fresh shell has to recompute every time.

An earlier run the same day showed a cache-miss slowdown caused by repeated path canonicalisation in isProtectedPath; it was fixed before these numbers were taken.

Read the fine print#

This is one Windows machine, one run, and the live p95 rests on only 20 samples - treat the numbers as a direction, not a guarantee. The method, the full component table and the raw samples are published in the repository: BENCHMARK-2026-11-07.md and BENCHMARK-2026-11-07.json.

Reproduce the component benchmark yourself:

npm run bench:tools -- --runs=100

All posts