tcmalloc

Crates.iotcmalloc
lib.rstcmalloc
version0.3.0
sourcesrc
created_at2018-05-28 17:50:11.182102
updated_at2019-04-10 12:23:27.672229
descriptionDrop-in global allocator using tcmalloc
homepage
repositoryhttps://github.com/jmcomets/tcmalloc-rs
max_upload_size
id67492
size16,298
crates-io (github:technocreatives:crates-io)

documentation

https://docs.rs/tcmalloc

README

tcmalloc

A drop-in GlobalAlloc implementation using tcmalloc from gperftools.

Travis badge crates.io badge

Usage

Requires Rust 1.28+

extern crate tcmalloc;

use tcmalloc::TCMalloc;

#[global_allocator]
static GLOBAL: TCMalloc = TCMalloc;

Also note that you can only define one global allocator per application.

By default this crate expects to link to a system-installed tcmalloc. To build the bundled copy of tcmalloc, enable the "bundled" feature. Note the caveats about profiling and libunwind/libgcc on 64-bit linux — they are not built by this crate, and tcmalloc will silently link to versions of both that can cause profiling deadlocks.

Commit count: 22

cargo fmt