Skip to main content
Glama

set_register

Assign a value to a held PlayStation 2 program's register—general, PC, HI/LO, status, FPU, or VU0—to redirect execution, skip a breakpoint, or inject test values.

Instructions

Gives a register of a held program a value: a general register by its name (v0, a0, sp, ra...), pc, hi, lo or status; f0 to f31 or acc of the FPU, fcr31; hi1, lo1 or sa. Setting pc is how a program is sent on from somewhere else, past a break instruction of its own, say. A general register takes up to 128 bits; a negative value is sign-extended. An FPU register takes a number with a point in it, 1.5 or "1.5", as that number in single precision, and anything else as its bits. VU0's vf1 to vf31 take four numbers, x, y, z and w, as "1.0, 2.0, 3.0, 4.0", or 128 bits; vi1 to vi15 take 16 bits.

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": {
      "register": "<register>",
      "value": "<value>"
    },
    "name": "set_register"
  }
}

Input Schema

NameRequiredDescriptionDefault
valueYes
registerYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full burden. It does disclose coercion behavior well: general registers hold up to 128 bits with sign-extension of negatives, FPU registers interpret a decimal number as single-precision or otherwise as raw bits, and VU0 vf registers accept either four comma-separated floats or 128 bits. It does not state preconditions (whether the program must be halted), permission needs, or what happens on an invalid register name or overflowing value.

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 purpose is front-loaded in the first clause, and the remaining prose is conditional detail keyed to register families rather than filler. It is dense and slightly run-on (the phrase 'as that number in single precision, and anything else as its bits' needs a second read), but no sentence is expendable.

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?

An output schema exists, so return values need not be described, and the value/register semantics are covered thoroughly for a two-parameter mutation tool. The remaining gap is the operating precondition implied only obliquely by 'a held program' and the absence of any failure-mode guidance, which matters for a state-changing tool with no annotations.

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

Parameters5/5

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

Schema coverage is 0% and neither parameter is described in the schema, so the description must compensate entirely, which it does: it defines the register namespace by category and explains precisely how the polymorphic value field (integer/number/string) is interpreted for each register class. This is exactly the meaning the anyOf schema cannot convey on its own.

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?

Opens with a specific verb-plus-resource: assigns a value to a register of a held program, then enumerates the register families it accepts (general names like v0/a0/sp/ra, pc, hi, lo, status, f0-f31, acc, fcr31, hi1/lo1/sa, VU0 vf/vi). That is enough for an agent to tell this apart from the read-only 'registers' sibling, though no sibling is named explicitly.

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

Usage Guidelines3/5

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

One concrete usage scenario is given (setting pc to move a program past its own break instruction), which implies the tool is for state manipulation during debugging. There is no explicit statement of when not to use it, nor a pointer to the 'registers' sibling for reading values, so routing must be inferred.

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