Skip to content
Beskid The Beskid Book

Beskid

Jump to a Beskid service

Beskid

Jump to a Beskid service

14.4 Codegen and IR

beskid_codegen lowering to CodegenArtifact and Cranelift IR.

Codegen and IR

Lowering is where typed programs become machine-oriented artifacts the engine can JIT or AOT.

beskid_codegen::lower_source / lower_program — see Build pipeline overview and Backends JIT/AOT.

OutputConsumer
CodegenArtifactbeskid_engine (JIT), beskid_aot (object/link)
ABI metadatabeskid_abi tables consumed by runtime

Typed emitter/transform contracts: Typed emitter and transforms. Lowering runs after merged typed AST is valid.

Spawn lowers to fiber_spawn; builtins align with Builtins and symbols—codegen must not invent alternate calling conventions.

JIT run