Skip to main content
Glama

lldb_images

List loaded executable images and shared libraries with addresses and file paths for debugging C/C++ programs. Filter results by name pattern to analyze program structure.

Instructions

List loaded executable images and shared libraries.

Shows: - Main executable - Shared libraries (.so, .dylib, .dll) - Load addresses - File paths Args: params: ImageListInput with executable and optional filter Returns: str: List of loaded images with addresses

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Implementation Reference

  • The handler function that executes the lldb_images tool logic, running LLDB commands to list loaded images and applying optional filtering.
    async def lldb_images(params: ImageListInput) -> str: """List loaded executable images and shared libraries. Shows: - Main executable - Shared libraries (.so, .dylib, .dll) - Load addresses - File paths Args: params: ImageListInput with executable and optional filter Returns: str: List of loaded images with addresses """ commands = [f"target create {params.executable}", "image list"] result = _run_lldb_script(commands) output = result["output"] # Apply filter if specified if params.filter_pattern and result["success"]: filtered_lines = [ line for line in output.split("\n") if params.filter_pattern.lower() in line.lower() ] output = "\n".join(filtered_lines) if filtered_lines else "No images matching filter" return f"## Loaded Images\n\n```\n{output.strip()}\n```"
  • The MCP tool registration decorator that registers the lldb_images tool with name and annotations.
    @mcp.tool( name="lldb_images", annotations={ "title": "List Loaded Images", "readOnlyHint": True, "destructiveHint": False, "idempotentHint": True, "openWorldHint": False, }, )
  • Pydantic input schema for the lldb_images tool parameters.
    class ImageListInput(BaseModel): """Input for listing loaded images/modules.""" model_config = ConfigDict(str_strip_whitespace=True) executable: str = Field(..., description="Path to the executable", min_length=1) filter_pattern: str | None = Field(default=None, description="Filter images by name pattern")

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/benpm/claude_lldb_mcp'

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