-
Notifications
You must be signed in to change notification settings - Fork 112
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix allocations with small limits exceeding limits
To ensure that allocations do not exceed the allocation limit imposed on a `Bump`, the logic for calculating the final size of an allocated chunk was factored out into a separate function so that the limit enforcing code higher up in the control flow could more strictly enforce the allocation limit, as previously this code did not have visibility into the final size of an allocation request. To ensure that allocations in arenas with small limits could succeed, `alloc_layout_slow` was changed to allow bypassing the minimum chunk size for new chunks when trying to allocate in new arenas when the limit was lower than the default minimum chunk size.
- Loading branch information
Showing
2 changed files
with
125 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters