Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

axiom-lldb

БесплатноБез исполняемых скриптовНе проверен

Use when ANY runtime debugging is needed — setting breakpoints, inspecting variables, evaluating expressions, analyzing threads, or reproducing crashes…

ComeOnOliverот ComeOnOliver★ 67 звёзд на GitHub

Об этом скилле

LLDB Debugging

Interactive debugging with LLDB. The debugger freezes time so you can interrogate your running app — inspect variables, evaluate expressions, navigate threads, and understand exactly why something went wrong.

Core insight: "LLDB is useless" really means "I don't know which command to use for Swift types." This is a knowledge-gap problem, not a tool problem.

Red Flags — Check This Skill When

Symptom This Skill Applies
Need to inspect a variable at runtime Yes — breakpoint + inspect
Crash you can reproduce locally Yes — breakpoint before crash site
Wrong value at runtime but code looks correct Yes — step through and inspect
Need to understand thread state during hang Yes — pause + thread backtrace
po doesn't work / shows garbage Yes — Playbook 3 has alternatives
Crash log analyzed, need to reproduce Yes — set breakpoints from crash context
Need to test a fix without rebuilding Yes — expression evaluation
Want to break on all exceptions Yes — exception breakpoints
App feels slow but responsive No — use axiom-performance-profiling
Memory grows over time No — use axiom-memory-debugging first
App completely frozen Maybe — use axiom-hang-diagnostics first, then LLDB for thread inspection
Crash in production, no local repro No — use axiom-testflight-triage first

LLDB vs Other Tools

digraph tool_selection {
    "What do you need?" [shape=diamond];

    "axiom-testflight-triage" [shape=box];
    "axiom-hang-diagnostics" [shape=box];
    "axiom-memory-debugging" [shape=box];
    "axiom-performance-profiling" [shape=box];
    "LLDB (this skill)" [shape=box, style=bold];

    "What do you need?" -> "axiom-testflight-triage" [label="Crash log from field,\ncan't reproduce locally"];
    "What do you need?" -> "axiom-hang-diagnostics" [label="App frozen,\nneed diagnosis approach"];
    "What do you need?" -> "axiom-memory-debugging" [label="Memory growing,\nneed leak pattern"];
    "What do you need?" -> "axiom-performance-profiling" [label="Need to measure\nCPU/memory over time"];
    "What do you need?" -> "LLDB (this skill)" [label="Need to inspect state\nat a specific moment"];
}

Rule of thumb: Instruments measures. LLDB inspects. If you need to understand what's happening at a specific moment in time, use LLDB. If you need to understand trends over time, use Instruments.

Response Format

When helping with LLDB debugging, structure your output as:

  1. Immediate diagnosis (1-3 bullets, confidence-tagged: HIGH/MEDIUM/LOW)
  2. Commands to run (numbered, copy-paste ready, with (lldb) prefix)
  3. What to look for (command → expected output → interpretation)
  4. Likely root causes (ranked by probability)
  5. Next breakpoint plan (catch it earlier next time)
  6. If no debugger attached (crash-log-only fallback path)

Playbook 1: Crash Triage

Goal: Understand why the app crashed, starting from the stop point.

Step 1: Read the Stop Reason

When the debugger stops, the first thing to check:

(lldb) thread info

This shows the stop reason. Common stop reasons:

Stop Reason Meaning Next Step
EXC_BAD_ACCESS (SIGSEGV) Accessed invalid memory (null pointer, dangling reference) Check the address — 0x0 to 0x10 = nil dereference
EXC_BAD_ACCESS (SIGBUS) Misaligned or invalid address Usually C interop or unsafe pointer issue
EXC_BREAKPOINT (SIGTRAP) Hit a trap — Swift runtime check failed Check for fatalError(), preconditionFailure(), force-unwrap of nil, array out of bounds
EXC_CRASH (SIGABRT) Deliberate abort — assertion or uncaught exception Look at "Application Specific Information" for the message
breakpoint Your breakpoint was hit Normal — inspect state

Step 2: Get the Backtrace

(lldb) bt

Read top-to-bottom. Find the first frame in YOUR code (not system frameworks). That's where to start investigating.

(lldb) bt 10

Limit to 10 frames if the full trace is noisy.

Step 3: Navigate to Your Frame

(lldb) frame select 3

Jump to frame 3 (or whichever frame is in your code).

Step 4: Inspect State

(lldb) v
(lldb) v self.someProperty
(lldb) v localVariable

Use v (not po) for reliable Swift value inspection. See Playbook 3 for details.

Step 5: Classify and Fix

Exception Type Typical Cause Fix Pattern
EXC_BAD_ACCESS at low address Force-unwrap nil optional guard let / if let
EXC_BAD_ACCESS at high address Use-after-free / dangling pointer Check object lifetime, [weak self]
EXC_BREAKPOINT Swift runtime trap (bounds, unwrap, precondition) Fix the violated precondition
SIGABRT Uncaught ObjC exception or fatalError() Read the exception message, fix the root cause

Полный SKILL.md на GitHub

Установить axiom-lldb в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл axiom-lldb?

Use when ANY runtime debugging is needed — setting breakpoints, inspecting variables, evaluating expressions, analyzing threads, or reproducing crashes interactively with LLDB

Как установить скилл axiom-lldb?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл axiom-lldb запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить axiom-lldb с