1 # Work in progress cranelift codegen backend for rust
3 > ⚠⚠⚠ This doesn't do anything useful yet ⚠⚠⚠
8 $ git clone https://github.com/bjorn3/rustc_codegen_cranelift.git
9 $ cd rustc_codegen_cranelift
10 $ rustup override set nightly
11 $ git submodule update --init
18 $ rustc -Zcodegen-backend=$(pwd)/target/debug/librustc_codegen_cranelift.so my_crate.rs --crate-type lib -Og
21 > You must compile with `-Og`, because checked binops are not yet supported.
26 $ git clone https://github.com/rust-lang/rust.git
28 $ git apply ../0001-Disable-stdsimd-in-libcore.patch
29 $ git apply ../0002-Disable-u128-and-i128-in-libcore.patch
34 > ⚠⚠⚠ You will get a panic because of unimplemented stuff ⚠⚠⚠
42 * [ ] Building libraries
43 * [ ] Other call abi's
55 * [ ] cranelift-module api seems to be used wrong, thus causing panic for some consts
56 * [ ] cranelift-codegen doesn't have encodings for some instructions for types smaller than I32