Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/snmalloc/backend/meta_protected_range.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ namespace snmalloc
LogRange<3>,
GlobalRange,
CommitRange<PAL>,
DecayRange<PAL, Pagemap>,
StatsRange>;

// Controls the padding around the meta-data range.
Expand Down
10 changes: 8 additions & 2 deletions src/snmalloc/backend/standard_range.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,14 @@ namespace snmalloc
LogRange<2>,
GlobalRange>;

// Track stats of the committed memory
using Stats = Pipe<GlobalR, CommitRange<PAL>, StatsRange>;
// Decay range caches deallocated memory and gradually releases it
// back to the parent, avoiding expensive repeated decommit/recommit
// cycles for transient allocation patterns.
using DecayR = Pipe<GlobalR, CommitRange<PAL>, DecayRange<PAL, Pagemap>>;

// Track stats of the memory handed out (outside decay so stats
// methods are directly visible to StatsCombiner).
using Stats = Pipe<DecayR, StatsRange>;

private:
static constexpr size_t page_size_bits =
Expand Down
1 change: 1 addition & 0 deletions src/snmalloc/backend_helpers/backend_helpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include "buddy.h"
#include "commitrange.h"
#include "commonconfig.h"
#include "decayrange.h"
#include "defaultpagemapentry.h"
#include "empty_range.h"
#include "globalrange.h"
Expand Down
Loading
Loading