#allocator #mimalloc

sys mimalloc-sys

Rust FFI bindings to mimalloc

7 releases

✓ Uses Rust 2018 edition

0.1.6 Sep 12, 2019
0.1.5 Jul 4, 2019
0.1.1 Jun 22, 2019

#50 in Memory management

Download history 120/week @ 2019-11-01 198/week @ 2019-11-08 204/week @ 2019-11-15 296/week @ 2019-11-22 374/week @ 2019-11-29 346/week @ 2019-12-06 349/week @ 2019-12-13 142/week @ 2019-12-20 200/week @ 2019-12-27 215/week @ 2020-01-03 275/week @ 2020-01-10 177/week @ 2020-01-17 273/week @ 2020-01-24 343/week @ 2020-01-31 378/week @ 2020-02-07

898 downloads per month
Used in 2 crates



C 5K SLoC // 0.2% comments JavaScript 2K SLoC // 0.1% comments Visual Studio Project 2K SLoC Visual Studio Solution 142 SLoC Rust 123 SLoC // 0.2% comments C++ 57 SLoC

Raw C FFI bindings to mimalloc

This crates provides raw C FFI bindings to the mimalloc library.


The documentation of the FFI bindings can be found in [docs.rs].

Current mimalloc version: 1.0.1

Build dependencies: cmake.

Cargo features

The mimalloc CMake configuration is exposed with these features

  • stats: Print statistics at program exit
  • secure: Build in secure mode
  • check_full: Enable full internal checks and asserts
  • override: Overrides the malloc symbols with mimalloc symbols.

Platform support

The following table describes the supported platforms:

  • build: does the library compile for the target?
  • run: do our own tests pass on the target?
  • mimalloc: do mimalloc's tests pass on the target?
  • valgrind: do our own tests pass under valgrind?

Tier 1 targets are tested on all Rust channels (stable, beta, and nightly). All other targets are only tested on Rust nightly.

Apple targets: build run mimalloc valgrind


This project is licensed under either of

at your option.


Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in mimalloc-sys by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.