Used start of a slab for link.

This commit is contained in:
Matthew Parkinson
2019-05-08 15:29:43 +01:00
parent 17bbab4fe4
commit 7de46182a8
5 changed files with 65 additions and 42 deletions

20
difference.md Normal file
View File

@@ -0,0 +1,20 @@
# Difference from published paper
This document outlines the changes that have diverged from the published paper
on `snmalloc`.
1. Link no longer terminates the bump-free list. The paper describes a
complex invariant for how the final element of the bump-free list can
also be the link node.
We now have a much simpler invariant. The link is either 1, signifying
the block is completely full. Or not 1, signifying it has at least one
free element at the offset contained in link, and that contains the DLL
node for this sizeclass.
The bump-free list contains additional free elements, and the remaining
bump allocated space.
The value 1, is never a valid bump allocation value, as we initially
allocate the first entry as the link, so we can use 1 as the no more bump
space value.