agentsclimarketplace

Extract asm

Skill nmoinvaz/speedy-gonzales/skills/extract-asm

Claude commands that speed up everyday dev workflows

Install
npx -y skills add nmoinvaz/speedy-gonzales --skill extract-asm

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Extract assembly from an object file or assembly file, optionally for a specific function

SKILL.md

3.5 KB, ~1.0k tokens by cl100k_base, as published. Nobody here has run it

Prerequisites

The input must be a compiled object file (.o or .obj) or assembly file (.s or .asm). If you have source code, compile it first (e.g. via CMake build or standalone clang -S).

Arguments

  • $1 = input file (.o, .obj, .s, or .asm)
  • $2 = function name (optional — if omitted, disassemble the entire file)

Examples:

  • trees.c.o compress_block — single function
  • trees.c.o — entire file
  • trees.s my_function
  • trees.obj compress_block

Steps

1. Disassemble object files (.o / .obj)

Use the appropriate tool for the platform:

PlatformToolNotes
macOSllvm-objdumpShips with Xcode
LinuxobjdumpGNU binutils 2.32+
Windowsllvm-objdumpShips with VS LLVM/clang workload or standalone LLVM

Single function ($2 provided):

PlatformCommand
macOSllvm-objdump --disassemble-symbols=_<name> --no-show-raw-insn <file>
Linuxobjdump --disassemble=<name> --no-show-raw-insn <file>
Windowsllvm-objdump --disassemble-symbols=<name> --no-show-raw-insn <file>

Entire file ($2 omitted):

PlatformCommand
macOSllvm-objdump -d --no-show-raw-insn <file>
Linuxobjdump -d --no-show-raw-insn <file>
Windowsllvm-objdump -d --no-show-raw-insn <file>

Windows dumpbin fallback — if llvm-objdump is not available:

VSPATH=$(vswhere -latest -property installationPath)
cmd.exe /c "call \"${VSPATH}\VC\Auxiliary\Build\vcvarsall.bat\" amd64 >nul 2>&1 && dumpbin /disasm <file>.obj"

Then manually extract the function: find <function_name>: label, collect until the next label or summary line.

2. Extract from assembly files (.s / .asm)

Read the file directly. If $2 is provided, extract the named function:

  • Mach-O: Find _<function_name>:, collect until next ^_[a-zA-Z] label (excluding _Ltmp, _LCFI, _LBB prefixes).
  • ELF/other: Find <function_name>:, collect until the next function label.

3. Clean up and output

  • Filter out assembler directives (. prefix), comments (#, ;, //, @), and blank lines
  • Keep only instruction lines
  • Output the assembly to stdout with a summary line showing the instruction count

Symbol Names

Symbol names differ by platform — use this when passing to --disassemble-symbols or searching in .s files:

PlatformC function fooC++ function foo
macOS (Mach-O)_foo_Z3foov (Itanium mangled, _ prefixed)
Linux (ELF)foo_Z3foov (Itanium mangled)
Windows (PE/COFF)foo?foo@@YAXXZ (MSVC decorated)

Architecture Notes

ArchitectureKey details
x86-64offset(%reg) memory syntax. leaq (%rip) is PC-relative, not a load.
AArch64[reg, #offset] memory syntax. Loads: ldr, ldur, ldp, ldrb, ldrh, ldrsw. Stores: str, stur, stp, strb, strh. Apple Silicon compiles natively.
x86-64 (MSVC)Intel syntax (dest first): mov rax, [rcx+168]. Args in rcx, rdx, r8, r9. C++ names may be decorated (?name@@...).

CMake Build Paths

  • Unix: build/CMakeFiles/<target>.dir/<source>.o
  • Windows (Ninja): build/CMakeFiles/<target>.dir/<source>.obj
  • Windows (VS): build/CMakeFiles/<target>.dir/<config>/<source>.obj

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.