Skip to main content
Glama
walac

perf-mcp

by walac

perf_mem_report

Profile memory access latencies and data source (L1/L2/L3/DRAM) to identify cache-miss-heavy code and NUMA-unfriendly patterns.

Instructions

Memory access profiling: data source (L1/L2/L3/DRAM), latency, and load/store breakdown.

Use this to find cache-miss-heavy code or NUMA-unfriendly access patterns.

Key parameters:

  • sort: sort key for the histogram.

  • type: 'load' or 'store' to filter access type.

  • ldlat: load latency threshold in CPU cycles.

  • type_profile: show data type profile (DWARF-based).

  • phys_data: show physical memory addresses.

Output: memory access histogram with data source breakdown. Requires: perf mem record (or perf record -d).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cpuNoCPUs to filter
sortNoSort by key(s)
typeNoMemory operation type
eventNoEvent selector
forceNoDon't complain, do it
inputYesPath to perf.data file
ldlatNoLoad latency threshold in cycles
verboseNoVerbosity level (0-2)
vmlinuxNovmlinux pathname
all_userNoOnly show user space entries
phys_dataNoShow physical address data
all_kernelNoOnly show kernel space entries
type_profileNoShow data type profile
data_page_sizeNoShow data page size
field_separatorNoField separator
hide_unresolvedNoOnly display entries resolved to a symbol
dump_raw_samplesNoDump raw samples in ASCII

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

No annotations are provided, so the description must carry behavioral context. It discloses the output ('memory access histogram'), the prerequisite ('perf mem record or perf record -d'), and clarifies key behaviors like DWARF-based type profiling. It does not explicitly state read-only or side-effect-free behavior, but the 'report' framing implies non-mutating operation.

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

Conciseness5/5

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

The description is tight and well-structured: intro sentence, use-case sentence, key parameters, output, and requirement. Every sentence contributes value and nothing is extraneous.

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

Completeness4/5

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

For a 17-parameter tool with output schema and no annotations, the description covers the essential context: purpose, key parameters, output shape, and recording prerequisite. It doesn't explain all parameters, but the schema and output schema fill those gaps. Slight lack of interpretive guidance on reading the histogram.

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

Parameters4/5

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

All 17 parameters have schema descriptions (100% coverage), so baseline is 3. The description adds extra meaning by explaining 'type' values ('load'/'store'), 'ldlat' threshold units, 'type_profile' is DWARF-based, and 'phys_data' refers to physical memory addresses, going beyond the schema.

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

Purpose5/5

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

Description clearly states the tool performs memory access profiling with data source (L1/L2/L3/DRAM), latency, and load/store breakdown. It positions it for cache-miss and NUMA analysis, which distinguishes it from sibling perf tools like perf_c2c_report or perf_report.

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?

Explicitly says 'Use this to find cache-miss-heavy code or NUMA-unfriendly access patterns,' giving clear when-to-use guidance. However, it does not mention when not to use it or name specific alternative tools.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/walac/perf-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server