SaaSHub helps you find the best software and product alternatives Learn more →
Top 23 memory-allocation Open-Source Projects
-
scalene
Scalene: a high-performance, high-precision CPU, GPU, and memory profiler for Python with AI-powered optimization proposals
-
bdwgc
The Boehm-Demers-Weiser conservative C/C++ Garbage Collector (bdwgc, also known as bdw-gc, boehm-gc, libgc)
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
-
memory-allocators
Custom memory allocators in C++ to improve the performance of dynamic memory allocation
-
memory
STL compatible C++ memory allocator library using a new RawAllocator concept that is similar to an Allocator but easier to use and write.
-
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.
-
Hoard
The Hoard Memory Allocator: A Fast, Scalable, and Memory-efficient Malloc for Linux, Windows, and Mac.
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
-
rust-jemalloc-pprof
Convert jemalloc heap profiles to pprof to understand memory usage, fix memory leaks, and fix OOM Kills.
-
Arenas
Unmanaged arena memory allocators for C#/CSharp with easy interactions between managed and unmanaged references
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
I collected a list of profilers (also memory profilers, also specifically for Python) here: https://github.com/albertz/wiki/blob/master/profiling.md
Currently I actually need a Python memory profiler, because I want to figure out whether there is some memory leak in my application (PyTorch based training script), and where exactly (in this case, it's not a problem of GPU memory, but CPU memory).
I tried Scalene (https://github.com/plasma-umass/scalene), which seems to be powerful, but somehow the output it gives me is not useful at all? It doesn't really give me a flamegraph, or a list of the top lines with memory allocations, but instead it gives me a listing of all source code lines, and prints some (very sparse) information on each line. So I need to search through that listing now by hand to find the spots? Maybe I just don't know how to use it properly.
I tried Memray, but first ran into an issue (https://github.com/bloomberg/memray/issues/212), but after using some workaround, it worked now. I get a flamegraph out, but it doesn't really seem accurate? After a while, there don't seem to be any new memory allocations at all anymore, and I don't quite trust that this is correct.
There is also Austin (https://github.com/P403n1x87/austin), which I also wanted to try (have not yet).
Somehow this experience so far was very disappointing.
(Side node, I debugged some very strange memory allocation behavior of Python before, where all local variables were kept around after an exception, even though I made sure there is no reference anymore to the exception object, to the traceback, etc, and I even called frame.clear() for all frames to really clear it. It turns out, frame.f_locals will create another copy of all the local variables, and the exception object and all the locals in the other frame still stay alive until you access frame.f_locals again. At that point, it will sync the f_locals again with the real (fast) locals, and then it can finally free everything. It was quite annoying to find the source of this problem and to find workarounds for it. https://github.com/python/cpython/issues/113939)
Project mention: WhatsApp forces Pegasus spyware maker to share its secret code | news.ycombinator.com | 2024-03-02
use memprof
Project mention: Talc – A fast and flexible allocator for no_std and WebAssembly | news.ycombinator.com | 2024-02-28Added a new issue [1] to add TLSF to the benchmarks as it's likely going to be faster in a single-threaded environment according to the rlsf crate [2].
[1] https://github.com/SFBdragon/talc/issues/26
If you need a sub-allocator with predictable performance feel free to give it a try. The code is here and it is licensed under the 0BSD license, making it as lax and as close to public domain as possible. Comments, issues and PRs are always welcomed and appreciated. Thanks!
Project mention: MiniMalloc: A Lightweight Memory Allocator for Hardware-Accelerated ML | news.ycombinator.com | 2024-01-30
Project mention: Convert jemalloc heap profiles to pprof to understand memory usage | news.ycombinator.com | 2023-12-27
Never heard of this concept I found this
https://github.com/Enichan/Arenas
For C#.
Been trying to get into more managed memory in C#, so this might be something good for that.
memory-allocation related posts
-
WhatsApp forces Pegasus spyware maker to share its secret code
-
Talc – A fast and flexible allocator for no_std and WebAssembly
-
EncroChat
-
Popular XMPP App "Conversations" Removed from PlayStore by Google
-
No new iPhone? No secure iOS: Looking at an unfixed iOS vulnerability
-
Recommendations for an Android repair shop?
-
Iphone Vs Android
-
A note from our sponsor - SaaSHub
www.saashub.com | 2 May 2024
Index
What are some of the best open-source memory-allocation projects? This list will help you:
Project | Stars | |
---|---|---|
1 | scalene | 11,174 |
2 | bdwgc | 2,795 |
3 | memory-allocators | 1,581 |
4 | memory | 1,441 |
5 | hardened_malloc | 1,158 |
6 | Hoard | 1,058 |
7 | zpl | 961 |
8 | pointers.py | 883 |
9 | php-memory-profiler | 836 |
10 | allocscope | 544 |
11 | rmm | 425 |
12 | LArray | 400 |
13 | talc | 381 |
14 | Heap-Layers | 369 |
15 | buddy_alloc | 120 |
16 | small | 98 |
17 | qCUDA | 87 |
18 | minimalloc | 86 |
19 | rust-jemalloc-pprof | 79 |
20 | Arenas | 77 |
21 | rulloc | 76 |
22 | memlimiter | 69 |
23 | bbai-kernel | 49 |
Sponsored