switch_get_pc
Retrieve the current program counter offset relative to main's base address for debugging Nintendo Switch executables in gdb-multiarch.
Instructions
Get the current PC as an offset relative to the base of main.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/gdb_multiarch_mcp/server.py:377-381 (registration)The 'switch_get_pc' tool is registered here with its description and input schema.
Tool( name="switch_get_pc", description="Get the current PC as an offset relative to the base of main.", inputSchema=NO_ARGS_SCHEMA, ), - src/gdb_multiarch_mcp/server.py:544-545 (handler)The handler for 'switch_get_pc' which executes the 'get_pc' command via the session.
elif name == "switch_get_pc": result = session.execute_command("get_pc")