Provides expertise for analyzing DWARF debug files and understanding the DWARF debug format/standard (v3-v5). Triggers when understanding DWARF information, interacting with DWARF files, answering DWARF-related questions, or working with code that parses DWARF data.
View on GitHubtrailofbits/skills
dwarf-expert
January 24, 2026
Select agents to install to:
npx add-skill https://github.com/trailofbits/skills/blob/main/plugins/dwarf-expert/skills/dwarf-expert/SKILL.md -a claude-code --skill dwarf-expertInstallation paths:
.claude/skills/dwarf-expert/# Overview This skill provides technical knowledge and expertise about the DWARF standard and how to interact with DWARF files. Tasks include answering questions about the DWARF standard, providing examples of various DWARF features, parsing and/or creating DWARF files, and writing/modifying/analyzing code that interacts with DWARF data. ## When to Use This Skill - Understanding or parsing DWARF debug information from compiled binaries - Answering questions about the DWARF standard (v3, v4, v5) - Writing or reviewing code that interacts with DWARF data - Using `dwarfdump` or `readelf` to extract debug information - Verifying DWARF data integrity with `llvm-dwarfdump --verify` - Working with DWARF parsing libraries (libdwarf, pyelftools, gimli, etc.) ## When NOT to Use This Skill - **DWARF v1/v2 Analysis**: Expertise limited to versions 3, 4, and 5. - **General ELF Parsing**: Use standard ELF tools if DWARF data isn't needed. - **Executable Debugging**: Use dedicated debugging tools (gdb, lldb, etc) for debugging executable code/runtime behavior. - **Binary Reverse Engineering**: Use dedicated RE tools (Ghidra, IDA) unless specifically analyzing DWARF sections. - **Compiler Debugging**: DWARF generation issues are compiler-specific, not covered here. # Authoritative Sources When specific DWARF standard information is needed, use these authoritative sources: 1. **Official DWARF Standards (dwarfstd.org)**: Use web search to find specific sections of the official DWARF specification at dwarfstd.org. Search queries like "DWARF5 DW_TAG_subprogram attributes site:dwarfstd.org" are effective. 2. **LLVM DWARF Implementation**: The LLVM project's DWARF handling code at `llvm/lib/DebugInfo/DWARF/` serves as a reliable reference implementation. Key files include: - `DWARFDie.cpp` - DIE handling and attribute access - `DWARFUnit.cpp` - Compilation unit parsing - `DWARFDebugLine.cpp` - Line number information - `DWARFVerifier.cpp` - Validation logic 3. **libdwar