14 releases (4 stable)

2.0.0 Jun 16, 2021
1.0.2 Feb 5, 2021
1.0.0-rc1 Dec 23, 2020
1.0.0-alpha5 Nov 6, 2020

#430 in WebAssembly

Download history 200/week @ 2021-04-04 358/week @ 2021-04-11 135/week @ 2021-04-18 108/week @ 2021-04-25 92/week @ 2021-05-02 45/week @ 2021-05-09 83/week @ 2021-05-16 35/week @ 2021-05-23 113/week @ 2021-05-30 72/week @ 2021-06-06 163/week @ 2021-06-13 279/week @ 2021-06-20 98/week @ 2021-06-27 157/week @ 2021-07-04 191/week @ 2021-07-11 143/week @ 2021-07-18

477 downloads per month
Used in 4 crates

MIT license

1MB
26K SLoC

wasmer-compiler-llvm Build Status Join Wasmer Slack MIT License crates.io

This crate contains a compiler implementation based on the LLVM Compiler Infrastructure.

Usage

use wasmer::{Store, Universal};
use wasmer_compiler_llvm::LLVM;

let compiler = LLVM::new();
// Put it into an engine and add it to the store
let store = Store::new(&Universal::new(compiler).engine());

Note: you can find a full working example using LLVM compiler here.

When to use LLVM

We recommend using LLVM as the default compiler when running WebAssembly files on any production system, as it offers maximum peformance near to native speeds.

Requirements

The LLVM compiler requires a valid installation of LLVM in your system. It currently requires LLVM 10.

You can install LLVM easily on your Debian-like system via this command:

bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)"

Or in macOS:

brew install llvm

Or via any of the pre-built binaries that LLVM offers.

Dependencies

~11MB
~225K SLoC