Go to file
2018-11-16 17:54:57 +01:00
alloc_system Rustup to rustc 1.32.0-nightly (ca79ecd69 2018-11-11) 2018-11-12 19:37:54 +01:00
example Add some benchmarks 2018-11-05 18:42:43 +01:00
src Move trapping to trap_code.rs 2018-11-16 17:35:47 +01:00
xargo Rustup to rustc 1.32.0-nightly (ca79ecd69 2018-11-11) 2018-11-12 19:37:54 +01:00
.gitignore Some more changes 2018-10-10 19:04:20 +02:00
.travis.yml [Travis] test on macOS too 2018-11-07 14:07:12 +01:00
0001-Disable-stdsimd.patch Rustup to rustc 1.32.0-nightly (ca79ecd69 2018-11-11) 2018-11-12 19:37:54 +01:00
0002-Disable-u128-and-i128-in-libcore.patch Rustup to rustc 1.32.0-nightly (65204a97d 2018-11-12) 2018-11-13 18:25:21 +01:00
0003-Disable-inline-assembly-in-spin_loop_hint.patch Implement a lot of atomic intrinsics 2018-10-06 10:24:09 +02:00
0004-Disable-some-more-unsupported-stuff-in-libcore.patch Rustup to rustc 1.31.0-nightly (de3d640f5 2018-10-01), fix a atomic bug and implement intrinsic bitreverse 2018-10-02 18:12:03 +02:00
0005-Disable-compiler_builtins.patch Add some more patches 2018-10-06 14:57:06 +02:00
0006-alloc-Disable-some-unsupported-stuff.patch Implement ProjectionElem::ConstantIndex 2018-11-13 18:28:10 +01:00
0007-Fix-libstd-building.patch Add some more patches 2018-10-06 14:57:06 +02:00
0008-Replace-some-variadic-function-calls-with-unimplemen.patch Replace some variadic function calls in libstd with unimplemented!() 2018-11-15 11:47:19 +01:00
build.sh Disable alloc_example and compile mod_bench_inline's sysroot with -Zmir-opt-level=3 2018-11-11 11:40:41 +01:00
Cargo.lock Update Cargo.lock 2018-11-16 17:54:57 +01:00
Cargo.toml Bump ar from 0.6.0 to 0.6.1 2018-11-14 13:34:34 +00:00
copy.clif Fix some bugs 2018-08-08 10:26:25 +02:00
LICENSE-APACHE Create LICENSE-APACHE 2018-06-22 19:33:35 +02:00
LICENSE-MIT Add LICENSE-MIT 2018-06-22 19:34:27 +02:00
prepare_libcore.sh Rustup to rustc 1.32.0-nightly (ca79ecd69 2018-11-11) 2018-11-12 19:37:54 +01:00
Readme.md Update Readme.md for the current state and add some links to tracking issues 2018-11-16 17:05:59 +01:00
rust-toolchain Initial commit 2018-06-17 18:05:11 +02:00

Work in progress cranelift codegen backend for rust

⚠⚠⚠ This doesn't do much useful yet ⚠⚠⚠

Building

$ git clone https://github.com/bjorn3/rustc_codegen_cranelift.git
$ cd rustc_codegen_cranelift
$ rustup override set nightly # This uses unstable api's which will never be stabilized
$ cargo install xargo         # Used for building the sysroot
$ cargo install hyperfine     # Used for benchmarking in build.sh
$ cargo build

Usage

$ rustc -Zcodegen-backend=$(pwd)/target/debug/librustc_codegen_cranelift.so my_crate.rs

Build sysroot and test

$ rustup component add rust-src # Make sure the sysroot source is availablr
$ ./prepare_libcore.sh          # Patch the sysroot source for some not yet supported things
$ ./build.sh

Not yet supported