Files
betterxen/docs/research/shader-containers.md
Ranveer Soni 96cff7c66e feat: establish native RDNA-to-Metal recompilation foundation
Add gfx1030 decoding, semantic validation, Metal shader generation, and an independent CPU interpreter for three reproducible compute fixtures. Include native Metal tests, LLVM fixture verification, and the existing CI and Phase 01 handoff.

Verified formatting, all-features Clippy and tests, LLVM decoding, native ARM64 linkage, and all three demo fixtures with Metal API and shader validation enabled.

Signed-off-by: Ranveer Soni <git@ranveersoni.me>
2026-11-22 13:41:55 +05:30

1.6 KiB

Shader inputs and provenance

Use original assembly assembled by llvm-mc for gfx1030. Preserve its exact tool version and target options, byte range and endianness, object and extracted code digests, and independently derived outputs. Pass the validated code range and explicit stage and architecture through the Xenora fixture interface. Use a symbol or a declared code range when extracting from an object so alignment bytes and padding do not enter execution. An AMDHSA object also has a separate documented code object ABI (CLAIM-LLVM-GFX1030). LLVM AMDGPU usage and code object layout

The documented DirectX container can carry either DXBC or DXIL shader parts. Its outer DXBC magic identifies the container structure. A DXIL program part contains versioned LLVM bitcode (CLAIM-DXCONTAINER-PAYLOAD). A self-authored HLSL shader compiled with public DXC remains a possible separate input path for later work. Apple's shader converter documents DXIL input to a Metal library (CLAIM-MSC-DXIL). LLVM DXContainer, Microsoft DXIL format, Apple shader converter

The public HlslCompile sample identifies a serialized console pipeline path (CLAIM-XBOX-ACO-SAMPLE). A public binary layout and validation contract for that path remain unresolved (CLAIM-XBOX-ISA-ABI). The synthetic input contract requires no Xbox toolchain or game assets.