`static-alloc`: Implement a speedy version of `alloc_zeroed`
- Dominant language
- Rust
- Stars
- 62
- Forks
- 11
- Avg merge
- 3h 45m
- Merged PRs (30d)
- 5
Description
In a special case, when the original constructor was `zeroed`, then the function does not need to perform its own zeroing of memory. This is helped by the fact that there is no reset function.
This could be implemented by a simple `bool` attribute containing the information on whether all of its remaining memory is zeroed.
Contributor guide
No contributing guide indexed for this repository
Research direction
Look at the `static-alloc` crate's source, particularly the `alloc_zeroed` function and the data structures that track memory state. The issue suggests adding a boolean attribute to track if remaining memory is already zeroed. Start by understanding how memory allocation and zeroing currently work, then modify the relevant struct and the `alloc_zeroed` implementation to skip zeroing when appropriate. Run existing tests to ensure correctness.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100