assembly
Skill15 starsChanged 46 days agoMITView on GitHub
Expert x86-64 and ARM64 assembly assistance covering registers, calling conventions, stack frames, and inline asm. Use when writing low-level code, optimizing hot loops, or reverse engineering binaries.
3 other projects use a version of this.
Adopted by
Most recently taken up by
- laceyp99/skillstheir own version, first seen Nov 16, 2026
- appautomaton/delineatetheir own version, first seen Oct 20, 2026
- iskron-ai/skillstheir own version, first seen Oct 9, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- appautomaton/delineate★ 3same name
- iskron-ai/skills★ 2same name
- laceyp99/skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository350 other files it gives its agents.
- airflowSkill
- catboostSkill
- claudeSkill
- comfyuiSkill
- cursor-aiSkill
- dalleSkill
- daskSkill
- dbtSkill
- deepseekSkill
- fastaiSkill
- geminiSkill
- github-copilotSkill
- huggingfaceSkill
- jaxSkill
- jupyterSkill
- kerasSkill
- langchainSkill
- lightgbmSkill
- llamaindexSkill
- llamaSkill
- matplotlibSkill
- midjourneySkill
- mistralSkill
- mlflowSkill
- nltkSkill
- numpySkill
- ollamaSkill
- openai-gptSkill
- opencvSkill
- pandasSkill
- perplexitySkill
- plotlySkill
- polarsSkill
- pytorchSkill
- raySkill
- scikit-learnSkill
- seabornSkill
- spacySkill
- sparkSkill
- stable-diffusionSkill
- tensorflowSkill
- vaexSkill
- weights-biasesSkill
- whisperSkill
- xgboostSkill
- api-gatewaySkill
- clean-architectureSkill
- cqrsSkill
- domain-driven-designSkill
- event-drivenSkill
- event-sourcingSkill
- graphqlSkill
- grpcSkill
- hexagonalSkill
- microservicesSkill
- modular-monolithSkill
- monolithSkill
- rest-apiSkill
- sagaSkill
- serverlessSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 122
Use Inline Assembly Sparingly in C/Rust: Rely on compiler intrinsic headers (<immintrin.h>) whenever possible instead of raw inline …
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Assembly
Low-level language with a very strong correspondence between the instruction in the language and the architecture's machine code instructions.
When to Use
- Low-Level Hardware & OS Kernel Programming: Writing bootloaders, CPU context switches, interrupt handlers, and page table setup.
- Micro-Architectural SIMD Vector Optimization: Crafting hand-tuned AVX-512, Neon, or SSE assembly kernels for game physics and matrix multiplication.
- Reverse Engineering & Exploit Analysis: Disassembling binary executables to audit firmware, analyze malware, or debug compiler crashes.
- Embedded Bare-Metal Firmware: Direct CPU register manipulation on microcontrollers without operating system abstractions.
Quick Start
section .data
msg db "Hello, World!", 0xa
len equ $ - msg
section .text
global _start
_start:
mov rax, 1 ; write syscall
mov rdi, 1 ; stdout
mov rsi, msg ; buffer
mov rdx, len ; length
syscall
mov rax, 60 ; exit syscall
xor rdi, rdi ; exit code 0
syscallCore Concepts
CPU Registers & Memory Addressing Modes (x86-64 / ARM64)
Registers hold immediate state for execution; addressing modes compute memory operands:
; x86-64 NASM: Moving data and base-index-scale-displacement addressing
mov rax, 42 ; Immediate to register
mov rbx, [rsp + 16] ; Base + displacement
mov rcx, [rdi + rsi * 8 + 32] ; Base + index * scale + displacementThe System V AMD64 Calling Convention
Governs how functions receive parameters and return values in Linux and macOS:
| Register | Argument Role |
rdi | 1st function argument |
rsi | 2nd function argument |
rdx | 3rd function argument |
rcx | 4th function argument |
r8, r9 | 5th and 6th function arguments |
rax | Function return value (and syscall number) |
; Direct 64-bit Linux syscall (sys_write = 1)
mov rax, 1 ; syscall: sys_write
mov rdi, 1 ; file descriptor: stdout (1)
mov rsi, msg ; pointer to buffer
mov rdx, 14 ; count (bytes)
syscall ; invoke kernelSIMD Vectorization (AVX-512 / AVX2)
Processes multiple data elements simultaneously across 256-bit or 512-bit vector registers:
; Add 8 single-precision floats in parallel using AVX
vmovups ymm0, [rdi] ; Load 8 floats into YMM0
vmovups ymm1, [rsi] ; Load 8 floats into YMM1
vaddps ymm2, ymm0, ymm1 ; YMM2 = YMM0 + YMM1 in single clock cycle
vmovups [rdx], ymm2 ; Store resultCommon Patterns
Syscall Invocation with Proper Register Arguments (Linux x86-64)
Problem: Invoking kernel system calls directly without C runtime dependencies.
Solution:
Load syscall number into rax and arguments in rdi, rsi, rdx, r10, r8, r9:
section .text
global _start
_start:
; sys_write(fd: 1, buf: msg, len: 14)
mov rax, 1
mov rdi, 1
mov rsi, msg
mov rdx, 14
syscall
; sys_exit(code: 0)
mov rax, 60
xor rdi, rdi
syscall
section .data
msg db "Hello, Assembly", 10Best Practices
Do:
- Preserve Callee-Saved Registers: Always preserve
rbx,rsp,rbp,r12-r15across function boundaries. - Maintain 16-Byte Stack Alignment: Ensure
rspis 16-byte aligned before issuingcallinstructions to avoid segmentation faults in libc. - Use Inline Assembly Sparingly in C/Rust: Rely on compiler intrinsic headers (
<immintrin.h>) whenever possible instead of raw inline assembly. - Comment Every Assembly Routine Thoroughly: Document input register assumptions, output registers, and modified flags.
Don't:
- Rewrite algorithms in assembly without profiling: Modern LLVM/GCC compilers generate near-optimal machine code for standard loops.
- Ignore processor architecture differences: x86-64 CISC code is incompatible with ARM64 RISC instruction sets.
- Bypass platform calling conventions: Mixing calling conventions causes silent stack corruption and elusive crashes.
Troubleshooting
| Error | Cause | Solution |
Segmentation fault (core dumped) | Dereferencing invalid pointer or misaligned stack before call. | Ensure stack pointer rsp is 16-byte aligned before function calls. |
Undefined reference to '_start' | Linker entrypoint missing or global _start not exported. | Declare global _start or compile with gcc -nostartfiles. |
relocation R_X86_64_32S against ... can not be used | Position-independent executable (PIE) requires RIP-relative addressing. | Use [rel symbol] addressing in NASM. |
References
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

