allocator-suite

Crates.ioallocator-suite
lib.rsallocator-suite
version0.1.7
sourcesrc
created_at2019-11-02 23:33:43.577278
updated_at2020-08-11 16:50:17.320094
descriptionAllocator Suite for various allocation types
homepagehttps://github.com/bastion-rs/allocator-suite
repositoryhttps://github.com/bastion-rs/allocator-suite
max_upload_size
id177636
size235,015
Theo M. Bulut (vertexclique)

documentation

https://docs.rs/allocator-suite

README

Allocator Suite

This crate is mostly rewritten version of context-allocator crate. It contains better NUMA-aware global allocator with hygienic macros. Contains better likelihood paths and faster execution paths.

Usage

#![feature(allocator_api)]
#![feature(extern_types)]
#![feature(core_intrinsics)]
#![feature(libstd_sys_internals)]
#![feature(thread_local)]
#![feature(const_fn)]

// Allocator generator macro
use allocator_suite::switchable_allocator;

// General imports
use allocator_suite::adaptors::prelude::*;
use std::alloc::System;

switchable_allocator!(
    application_allocator,
    BumpAllocator<ArenaMemorySource<MemoryMapSource>>,
    MultipleBinarySearchTreeAllocator<MemoryMapSource>,
    GlobalAllocToAllocatorAdaptor<System>,
    GlobalAllocToAllocatorAdaptor(System)
);
Commit count: 47

cargo fmt