X-Lang logo
GitHub

Compiler Intent,Proven End-To-End

X-Lang combines explicit semantic contracts, translation validation, and advisor-driven diagnostics to push beyond conservative heuristics while preserving correctness.

Semantic Contracts

Program intent is explicit, checkable, and consumable by lowering passes.

Translation Validation

Lean and Alive2 provide correctness guarantees across semantic and IR layers.

Actionable Advice

x-advisor catches negative synergy and ships practical remediations before runtime.

@layout(SoA)

Transforms Array-of-Structures into Structure-of-Arrays for contiguous access and stronger auto-vectorization.

X-Lang Source
1#[layout(SoA)]
2struct Particle {
3  x: f64,
4  y: f64
5}
6
7fn process(p: &mut [Particle]) {
8  p[i].x += 1.0;
9}
Generated LLVM IR
1; SoA handle generated by LayoutPass
2%Particle_SoA = type { ptr, ptr }
3%x_base = load ptr, ptr %field_ptr_addr
4%addr = getelementptr double, ptr %x_base, i64 %idx