Re:Talc – A fast and flexible allocator for no_std and WebAs...
by josephg on Thursday February 29, 2024 @01:57AM
(#39546998)
Thats a pretty big heap size for a wasm bundle! What are you doing in wasm that allocates so much and so often?
Re:Talc – A fast and flexible allocator for no_std and WebAs...
by IshKebab on Thursday February 29, 2024 @02:25AM
(#39547120)
34 MB? Doesn't seem that big to me.
Re:Talc – A fast and flexible allocator for no_std and WebAs...
by flohofwoe on Thursday February 29, 2024 @03:01AM
(#39547310)
At least I was also confused too because I was looking at total_allocated_bytes, but I guess that includes allocations that have been freed.
Re:Talc – A fast and flexible allocator for no_std and WebAs...
by sfbea on Thursday February 29, 2024 @03:09AM
(#39547351)
[Author of talc] Glad this feature is proving useful. Seeing this makes me think I should implement a better-looking Display implementation than the default Debug impl though. Something for the next update ^-^
In my console, I have something akin to this:
I haven't carefully benchmarked dlmalloc (Rust's default WASM allocator, https://github.com/alexcrichton/dlmalloc-rs), but it's nothing special (to my knowledge). The swap to Talc is pretty trivial and it's clear that the author is paying attention to its performance.