Skip to main content
Glama

Compare two recordings

perf_compare
Read-only

Compare two saved GPU performance recordings to see FPS, GPU ms, frame pacing, memory, and encoder workload changes, with flags for invalid comparisons and suggested next actions.

Instructions

Compares two saved recordings, a the reference and b the run after a change: headline numbers (FPS, GPU ms, frame pacing, memory), then the GPU work: encoders and command buffers per frame, share of short encoders, idle time, and each encoder label's change, largest first. layer says whether both ran on the same translation layer; measure marks Windows against Metal (use FPS, lows, stutter, jitter); runs under 100 frames are flagged. screen, noisy_environment flag runs that do not compare; suggested_actions says what to call next.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "a": "<a>",
      "b": "<b>"
    },
    "name": "perf_compare"
  }
}

Input Schema

NameRequiredDescriptionDefault
aYesrun name from perf_runs: the reference, such as the run before a change
bYesrun name from perf_runs: the run to compare against a
fieldsNoresult paths to keep, dotted: common.frame_pacing
skip_sNoseconds to leave out at the start (shaders compile, resources load), default 0; GPU numbers, hitches and Metal memory are recomputed without them
markdownNoalso return the numbers as Markdown tables, default false
short_usNoan encoder under this GPU time counts as short: 10, 25 (default), 50, 100, 250, 500 or 1000

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.28.0
    • addedInput schema / properties / fields
      Added value: +{
      +  "description": "result paths to keep, dotted: common.frame_pacing",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • changedInput schema / properties / skip_s / description
      Previous value: -"seconds to leave out at the start of each recording, where shaders compile and resources load; 0 (default) keeps all. The GPU numbers, hitches and Metal memory are recomputed without them"New value: +"seconds to leave out at the start (shaders compile, resources load), default 0; GPU numbers, hitches and Metal memory are recomputed without them"
  2. Changed1 schema field changedv0.18.0
    • addedInput schema / properties / skip_s
      Added value: +{
      +  "description": "seconds to leave out at the start of each recording, where shaders compile and resources load; 0 (default) keeps all. The GPU numbers, hitches and Metal memory are recomputed without them",
      +  "type": "number"
      +}
  3. Changed2 schema fields changedv0.10.1
    • addedInput schema / properties / markdown
      Added value: +{
      +  "description": "also return the numbers as Markdown tables, default false",
      +  "type": "boolean"
      +}
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "type": "object"
      +}
  4. Changed3 schema fields changedv0.7.1
    • addedInput schema / properties / a / description
      Added value: +"run name from perf_runs: the reference, such as the run before a change"
    • addedInput schema / properties / b / description
      Added value: +"run name from perf_runs: the run to compare against a"
    • addedInput schema / properties / short_us
      Added value: +{
      +  "description": "an encoder under this GPU time counts as short: 10, 25 (default), 50, 100, 250, 500 or 1000",
      +  "type": "integer"
      +}
  5. First observedv0.2.0

TDQS

A4.1/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the readOnlyHint and openWorldHint annotations, the description discloses the comparison output structure, including headline numbers, GPU work details, encoder changes, translation-layer status, Windows-vs-Metal measurement caveats, sub-100-frame flags, non-comparable run flags, and suggested next actions. It adds substantial behavioral context without contradicting the annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but front-loaded and avoids filler. It is somewhat packed into a single block, yet the progression from headline numbers to GPU details to caveats and flags is easy enough to follow.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the output schema and annotations, the description provides enough context for an agent to call and interpret this comparison tool. It covers output categories, comparison conditions, flagging behavior, and next-action guidance without needing to restate every schema field.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already defines a, b, fields, skip_s, markdown, and short_us. The description reinforces the a/b reference-vs-run-after-change distinction but does not add parameter syntax or semantics beyond what the schema provides.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: comparing two saved recordings, with a as the reference and b as the run after a change. It is clear what the tool does, but it does not distinguish itself from siblings such as perf_ab or perf_baseline.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives clear usage context by framing a as the reference and b as the run after a change, which implies when this tool is appropriate. It does not explicitly state when not to use it or name alternative comparison tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.