Decision Workspace
stackalloc vs alloca vs stack_frame_allocators
Side-by-side comparison of Rust crates
46
stackalloc
growingv1.2.1
Safely allocate and manipulate arbitrarily-sized slices on the stack at runtime
49
alloca
growingv0.4.0
Mostly safe wrapper for alloca
48
stack_frame_allocators
growingv1.1.2
A set of allocators based off the concept of the stack and creating "Frames". Push frames onto the Stack, push values onto Frames, and pop entire Frames and their items
Core Metrics
| stackalloc | alloca | stack_frame_allocators | |
|---|---|---|---|
| Health Score | 46 | 49 | 48 |
| Total Downloads | 35.1K | 7.6M | 4.1K |
| 30d Downloads | 2.4K | 2.8M | 7 |
| Dependents | 8 | 68 | 0 |
| Releases | 7 | 10 | 5 |
| Last Updated | 688d ago | 967d ago | 334d ago |
| Age | 5y | 5y 2m | 1y 5m |
Health Breakdown
stackalloc
Maintenance
4
Quality
22
Community
6
Popularity
5
Documentation
9
alloca
Maintenance
4
Quality
16
Community
11
Popularity
8
Documentation
10
stack_frame_allocators
Maintenance
8
Quality
20
Community
3
Popularity
4
Documentation
13
Technical Details
| stackalloc | alloca | stack_frame_allocators | |
|---|---|---|---|
| Version | 1.2.1 | 0.4.0 | 1.1.2 |
| Stable (≥1.0) | ✓ Yes | ✗ No | ✓ Yes |
| License | MIT | MIT | MIT OR Apache-2.0 |
| Dependencies | 3 | 1 | 0 |
| Crate Size | 11KB | 4KB | 15KB |
| Features | 3 | 1 | 0 |
| Yanked % | 0.0% | 0.0% | 0.0% |
| Edition | 2018 | 2021 | 2021 |
| MSRV | — | — | — |
| Owners | 1 | 1 | 1 |
Links
Quick Verdict
- •alloca leads with a health score of 49/100, but none of the options score above 80.
- •⚠ stackalloc, alloca have not been updated in over a year.
- •alloca is pre-1.0 — API may change.