mimalloc
rust

mimalloc | rust | |
---|---|---|
36 | 2,787 | |
10,963 | 101,313 | |
2.1% | 1.3% | |
9.6 | 10.0 | |
6 days ago | 1 day ago | |
C | Rust | |
MIT License | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
mimalloc
-
Improve an algorithm performance step by step
Switching to jemalloc or mimalloc doesn't improve the performance either.
- Mimalloc: High performance general purpose allocator
-
Replacing musl's malloc with mimalloc: any ideas?
mimalloc: mimalloc is an open source implementation of malloc, currently the best performing allocator.
-
Reptar
Some compiler writers thought that was the case, if [0] is related to OP. I don't have a "modern" (after 6th gen) Intel CPU to test it on, but note that most programs are compiled for a relatively generic CPU.
[0]: https://github.com/microsoft/mimalloc/issues/807
-
Is the JVM a upside or downside to Scala?
Yes, it's very efficient and that's not where the main problem lies. However, small allocations with modern C heap allocators like mimalloc or snmalloc has gotten extremely efficient as well. Would be interesting to see a benchmark comparison with Java's G1 and ZGC.
-
Z Garbage Collector: The Next Generation
Memory management for C is not itself a solved problem, not only is there a lot of performance to squeeze out of malloc itself (the benchmarks on https://github.com/microsoft/mimalloc exemplifies the variance between the implementations), but it's up to the programmer to implement memory management in the large in an efficient way, which is not an easy task. One sure mark of a slow C program is one with a ton of mallocs and frees strewn all over.
-
Linux Tech Tips EP#13: Testing Transparent Huge Pages and Cryo Utilities in Gaming | 3700X 6600XT
It's a very terse howto for replacing Factorio's memory allocator with Microsoft's mimalloc, and configuring mimalloc so that memory is always allocated on huge pages by using madvise().
-
Differences between Lean4 and Koka reference counting
I was wondering if Koka's perceus referencing counting style is any different from the reference counting that Lean4 implements? I understand that both rely upon the mimalloc (https://github.com/microsoft/mimalloc) library in the backend.
-
pmr implementation in c++14
If you are fine with heap allocations then there are only few dozens operator new/delete to override to regain control over normal C++ code memory use. Allocators and STL all need to call those. At least that's what gaming does on all platforms. If you need examples you can check Mimalloc on github ( https://github.com/microsoft/mimalloc/blob/master/include/mimalloc-new-delete.h ).
-
GitHub link to an Arma 3 allocator which increases performance by 20-50%
What's the difference between this and Microsoft's? https://github.com/microsoft/mimalloc
rust
-
Solving the ABA Problem in Rust with Tagged Pointers
modules are meant to be the boundary for a safe abstraction, but sometimes you get fun holes like https://github.com/rust-lang/rust/issues/128872 where you can implement Copy for a type in a different module in the same crate, even if the fields are private
- Resigning as Asahi Linux project lead
-
Rust Kernel Policy
>Use Zig as a zero-dependency, drop-in C/C++ compiler that supports cross-compilation out-of-the-box.
I know barely anything about Zig, so I don't know the veracity of this, however.
Rust's FFI also relies on undefined behavior if this comment isn't outdated https://github.com/rust-lang/rust/pull/59625#issuecomment-48... https://github.com/rust-lang/rust/blob/master/library/core/s... . Might not be an issue as long as the implementation is only used with LLVM and LLVM doesn't change.
-
Streaming Data from Cloud Storage with Mountpoint for Amazon S3
Mountpoint is a new FUSE based solution written in the Rust programming language and based on a Rust version of the Linux FUSE library. See here for an explanation of the choice of Rust. Other popular tools in the FUSE-based family of solutions are goofysand s3fs.
-
Ada crate of the year 2024 announced
Yep, and even without dynamic memory management, Ada is not type-safe: https://www.enyo.de/fw/notes/ada-type-safety.html
Rust also has problems: https://github.com/rust-lang/rust/issues/25860
-
It Is Time to Standardize Principles and Practices for Software Memory Safety
The bug used by that repository [1] isn't the only one that can be used to escape the Safe Rust type system. There are a couple others I've tried [2] [3], and the Rust issue tracker currently lists 92 unsoundness bugs (though only some of them are general-purpose escapes), and that's only the ones we know about.
These bugs are not really a problem in practice though as long as the developer is not malicious. However, they are a problem for supply chain security or any case where the Rust source is fully untrusted.
[1]: https://github.com/rust-lang/rust/issues/25860
[2]: https://github.com/rust-lang/rust/issues/57893
[3]: https://github.com/rust-lang/rust/issues/133361
-
Roc Rewrites the Compiler in Zig
Since at least 2018, there's been a planned upgrade to the borrow checker to permit certain patterns that it currently rejects [0]. Also since 2018, there's been an implementation of the new version (called Polonius) that can be enabled with an unstable compiler flag [1].
But it's 2025, and the new version still hasn't been enabled on stable Rust, since the Polonius implementation is seen as too slow for larger programs. A big goal of the types team since last year has been to reimplement a faster version within rustc [2].
I'd count this as a language feature (albeit a relatively minor one) that's been greatly deferred in favor of shorter compile times.
[0] https://blog.rust-lang.org/inside-rust/2023/10/06/polonius-u...
[1] https://github.com/rust-lang/rust/pull/51133
[2] https://rust-lang.github.io/rust-project-goals/2024h2/Poloni...
-
Rust's worst feature (available in Rust nightly)
> Is there evidence more baking won't happen?
No, actually there is a lot of evidence that it will still be worked on.
Normally I would just say look at the issue linked in the nightly docs but due to an overlap of tacking PR and moving it from std to core PR it's not supper useful.
Tracking Issue: https://github.com/rust-lang/rust/issues/78485
If the author has constructive critique they should probably mention it there (after skimming through the discussion to make sure this wasn't already considered and not done due to subtleties they overlooked in the blog post (like e.g. that it's a standard/core feature which has to work across all targets and as such can't rely on anything being initialized to 0 by the OS, or that depending on the global allocator used you definitely can't rely on things being zeroed even if the OS only hands out zeroed memory, etc. etc.))
-
I've been advocating for RSS support, and you should too
I recently had the need to subscribe to changes to a Github repo and it turns out it provides a feed for them. For rust master branch, for example, subscribe to https://github.com/rust-lang/rust/commits/master.atom.
- Rust's New Sort Algorithms
What are some alternatives?
jemalloc
carbon-lang - Carbon Language's main repository: documents, design, implementation, and related tools. (NOTE: Carbon Language is experimental; see README)
rpmalloc - Public domain cross platform lock free thread caching 16-byte aligned memory allocator implemented in C
zig - General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.
snmalloc - Message passing based allocator
Odin - Odin Programming Language
hardened_malloc - Hardened allocator designed for modern systems. It has integration into Android's Bionic libc and can be used externally with musl and glibc as a dynamic library for use on other Linux-based platforms. It will gain more portability / integration over time.
Nim - Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, and elegance (in that order of priority).
factorio-docker - Factorio headless server in a Docker container
hylo - The Hylo programming language
jemallocator - Rust allocator using jemalloc as a backend
go - The Go programming language
