feos-org / feos

FeOs - A Framework for Equations of State and Classical Density Functional Theory
Other
108 stars 22 forks source link

Add optional allocators #253

Open g-bauer opened 3 weeks ago

g-bauer commented 3 weeks ago

Adds mimalloc and jemalloc as optional allocators.

Use one of default, mimalloc, or jemalloc as rust flag to select allocator.

Example for mimalloc:

RUSTFLAGS="--cfg allocator=\"mimalloc\"" maturin build

The same can be used to run benches. Works with Pyhton package. mimalloc shows significant performance improvements for some cases (>20%).