Skip to content

add (Rust) simd-json and rebar to mimalloc-bench #249

@zooko

Description

@zooko

Hi folks! Thanks so much for maintaining mimalloc-bench. In developing my smalloc memory allocator, I've benefited from mimalloc-bench. Also I found two other projects from the Rust ecosystem that have benchmarks that I was able to adapt to use mimalloc, snmalloc, rpmalloc, and jemalloc, using Rust wrappers for each of those. Maybe you'd like to add this into mimalloc-bench (whether with the Rust wrappers or with mimalloc-bench's current LD_PRELOAD technique). They are https://github.com/simd-lite/simd-json and https://github.com/BurntSushi/rebar .

Here you can find my forks of those repos to run their benchmarks with various memory allocators: https://github.com/zooko/simd-json and https://github.com/zooko/rebar . And here are the instructions for how to run the benchmarks: https://github.com/zooko/smalloc/blob/main/bench/README.md#benchmarking-user-code-with-different-allocators

Here are some benchmark results generated with this process:

using the simd-json codebase:

test                                                                            default                jemalloc                snmalloc                mimalloc                rpmalloc                 smalloc
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
...
NORMALIZED (100s baseline work)                                      2100.0 s  (      )      2096.4 s  (      )      1944.6 s  (      )      1778.1 s  (      )      1756.2 s  (      )      1711.9 s  (      )
RELATIVE TO BASELINE                                                           ( +0.0%)                ( -0.2%)                ( -7.4%)                (-15.3%)                (-16.4%)                (-18.5%)

using the rebar codebase:

Engine               Version  Geometric mean of speed ratios  Benchmark count
------               -------  ------------------------------  ---------------
rust/regex-snmalloc  1.12.2   1.01                            52
rust/regex-rpmalloc  1.12.2   1.02                            52
rust/regex-smalloc   1.12.2   1.03                            52
rust/regex-mimalloc  1.12.2   1.03                            52
rust/regex-jemalloc  1.12.2   1.07                            52
rust/regex           1.12.2   1.09                            52

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions