Guide agents through Rust compiler invocation: RUSTFLAGS, Cargo profile configuration, build modes, MIR and assembly inspection, monomorphization, and common compilation error patterns.
| lto = true (fat) | Best optimization, slowest link | | lto = "thin" | Good optimization, parallel link | | codegen-units = 1 | Best inlining, slower compile | | panic = "abort" | Removes unwind tables, smaller binary | | opt-level = "z" | Aggressive size reduction |
Rust generics are monomorphized — each concrete type instantiation produces separate code. This causes:
Rust compiler skill for systems programming. Use when selecting RUSTFLAGS, configuring Cargo profiles, tuning release builds, reading assembly or MIR output, understanding monomorphization, or diagnosing compilation errors. Activates on queries about rustc flags, Cargo.toml profiles, opt-level, LTO, codegen-units, target-cpu, emit asm, MIR, or Rust build performance. Source: mohitmishra786/low-level-dev-skills.