abi-and-calling-conventions

Solid

Use when explaining System V AMD64, ARM AAPCS, RISC-V psABI, stack frames, variadic calls, or FFI register rules. Not for the Rust FFI binding layer: use rust-ffi.

AI & Automation 52 stars 9 forks Updated 5 days ago Apache-2.0

Install

View on GitHub

Quality Score: 83/100

Stars 20%
57
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# ABI and calling conventions ## Contract | Field | Bound contract | |---|---| | Trigger | A question or debugging session needs the register roles, stack alignment, argument passing, return value, or variadic rules of System V AMD64, ARM AAPCS, or the RISC-V psABI. | | Authority | Read-only. The skill reads source, disassembly, and compiler output and answers in chat. Nothing on disk changes, so there is nothing to roll back. No remote mutation. | | Side effect | Chat output only. Compiler and disassembler runs write nothing outside stdout. | | Done | The answer names the argument registers, return registers, stack alignment, callee-saved set, and variadic rule for the named ABI, and points to the compiler output that confirms it. | ## Inputs - Target ABI (required): System V AMD64, AAPCS64 (AArch64), or RISC-V psABI (RV64). If the user names Windows x64, see the failure table. - Calling context (required): an assembly thunk, inline asm clobber list, a mixed C and assembly boundary, a variadic wrapper, or an FFI signature. - Symptom (optional): a crash on `call`, a wrong argument value, or a corrupted register after a call. ## Procedure 1. Name the ABI from the toolchain target and the platform. Done when: one of the three ABIs is named, or the failure table applies. 2. State the register contract for that ABI. Done when: argument, return, alignment, and callee-saved rows are all given. | ABI | Integer arguments | Float or vector arguments | Return | Stack alignment a...

Details

Author
OutlineDriven
Repository
OutlineDriven/outline-driven-development
Created
9 months ago
Last Updated
5 days ago
Language
Python
License
Apache-2.0

Similar Skills

Semantically similar based on skill content — not just same category