fission-sleigh is Fission’s Rust-native Sleigh front-end crate.
It resolves local .slaspec files from a Ghidra-mirrored processor tree, compiles all checked-in variants into deterministic generated artifacts, and owns the new fail-closed compiled runtime registry.
The previous architecture-specific hand-lifter path has been removed.
utils/sleigh-specs/languages/<Processor>/**/*.slaspecruntime/build_cfg_blocks)compiler/)
@include, @define, conditional guards)generated/<Processor>/<entry-spec-stem>/x86-64: ExecutableCandidate, but p-code template execution is still incompleteRegisteredCompileOnly38 Ghidra processors146 checked-in .slaspec variantsutils/sleigh-specs/ghidra_language_manifest.jsonPrimary entrypoint:
RuntimeSleighFrontendSupporting types/functions:
DecodedPcodeFunctionDecodeContractDecodeStopReasonCompiledRuntimeRegistrybuild_cfg_blocksis_terminal_control_flowcrates/fission-sleigh/
├── src/
│ ├── lib.rs
│ ├── compiler/
│ │ ├── mod.rs
│ │ ├── token.rs
│ │ ├── preprocessor.rs
│ │ ├── ast.rs
│ │ ├── ir.rs
│ │ ├── codegen.rs
│ │ └── equivalence.rs
│ └── runtime/
│ ├── mod.rs
│ ├── spine/
│ │ ├── context.rs
│ │ ├── decision.rs
│ │ ├── construct.rs
│ │ ├── walker.rs
│ │ ├── template.rs
│ │ └── emitter.rs
│ ├── processors/
│ │ ├── aarch64/
│ │ ├── arm/
│ │ ├── mips/
│ │ ├── powerpc/
│ │ ├── riscv/
│ │ ├── ...
│ │ └── x86/
│ │ └── generated.rs
└── generated/
├── compiler_manifest.json
├── AARCH64/
├── ARM/
├── MIPS/
├── PowerPC/
├── RISCV/
├── ...
└── x86/
use fission_sleigh::runtime::RuntimeSleighFrontend;
fn main() -> anyhow::Result<()> {
// Example language names available in utils/sleigh-specs/languages/<Processor>/:
// - "x86-64"
// - "AARCH64"
// - "AARCH64:LE:64:v8A" (if derivable from checked-in .ldefs)
let runtime = RuntimeSleighFrontend::new_for_language("x86-64")?;
println!("status={}", runtime.status().as_str());
let bytes = [0x90, 0xC3]; // nop; ret
let address = 0x401000;
let (ops, len) = runtime.decode_and_lift_with_len(&bytes, address)?;
assert_eq!(len, 2);
assert!(!ops.is_empty());
Ok(())
}
RuntimeSleighFrontend::new_for_language("<name>") looks for:
utils/sleigh-specs/ghidra_language_manifest.jsonaarch64, arm32, powerpc, riscvFISSION_SLEIGH_SPEC_DIRutils/sleigh-specsvendor/ghidra/ghidra-Ghidra_12.0.4_build/Ghidra/Processors/*/data/languages/RuntimeSleighFrontend::new(path) infers language name from the file stem.The generated runtime is organized around Ghidra’s SLEIGH execution ownership, but implemented as dependency-free Rust:
| Ghidra owner | Fission owner |
|---|---|
SleighLanguage |
RuntimeSleighFrontend plus compiled language registry |
SleighParserContext |
runtime::spine::RuntimeInstructionContext |
DecisionNode |
CompiledDecisionTree plus runtime::spine::DecisionProbeEvaluator |
ConstructState |
runtime::spine::RuntimeConstructState |
ParserWalker |
runtime::spine::RuntimeParserWalker |
ConstructTpl |
compiler-produced constructor templates |
PcodeEmit |
runtime::spine::RuntimePcodeEmitter |
Processor-specific runtime modules may extract ISA fields such as prefixes, ModRM/SIB, context bits, address spaces, and register mappings. They must not own semantic repair or mnemonic-level p-code policy; that belongs in the shared spine and compiler-produced templates.
Runtime processor folders are checked in for all 38 mirrored Ghidra processors.
Only x86 is an executable candidate today; the remaining processor modules are
typed compile-only skeletons until their generated runtime parity gates are implemented.
From repository root:
cargo check -p fission-sleigh
cargo test -p fission-sleigh
cargo run -p fission-sleigh --example generate_sleigh_frontends
When changes may affect decompilation routing behavior:
cargo check -p fission-cli
fission-sleigh..slaspec variants with one generic compiler API.crates/fission-sleigh/generated/<Processor>/<entry-spec-stem>/.crates/fission-sleigh/generated/compiler_manifest.json.