10 releases (6 stable)

2.3.0 Jun 6, 2022
2.2.1 Mar 16, 2022
2.2.0 Feb 28, 2022
2.2.0-rc1 Jan 28, 2022
2.0.0 Jun 16, 2021

#1418 in WebAssembly

Download history 8328/week @ 2023-12-16 6002/week @ 2023-12-23 6670/week @ 2023-12-30 10348/week @ 2024-01-06 8300/week @ 2024-01-13 9331/week @ 2024-01-20 8487/week @ 2024-01-27 8990/week @ 2024-02-03 11175/week @ 2024-02-10 8415/week @ 2024-02-17 8417/week @ 2024-02-24 8849/week @ 2024-03-02 10590/week @ 2024-03-09 9876/week @ 2024-03-16 8975/week @ 2024-03-23 6973/week @ 2024-03-30

38,087 downloads per month
Used in 9 crates (via wasmer-asml-fork)

MIT license

1MB
18K SLoC

wasmer-engine-dylib Build Status Join Wasmer Slack MIT License

The Wasmer Dylib engine is usable with any compiler implementation based on wasmer-compiler that is able to emit Position-Independent Code (PIC).

After the compiler generates the machine code for the functions, the Dylib Engine generates a shared object file and links it via dlsym so it can be usable by the wasmer API.

This allows Wasmer to achieve blazing fast native startup times.

Note: you can find a full working example using the Dylib engine here.

Difference with wasmer-engine-universal

The Dylib Engine and Universal Engine mainly differ on how the Modules are loaded/stored. Using the same compilers, both will have the same runtime speed.

However, the Dylib Engine uses the Operating System shared library loader (via dlopen) and as such is able to achieve a much faster startup time when deserializing a serialized Module.

Requirements

The wasmer-engine-dylib crate requires a linker available on your system to generate the shared object file.

We recommend having gcc or clang installed.

Note: when cross-compiling to other targets, clang will be the default command used for compiling.

You can install LLVM (that provides clang) 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

~9–21MB
~298K SLoC