Move link out of object space.
The link object was previously stored in a disused object. This is good for reducing meta-data, but if we want to reduce the meta-data corruption potential, then this is not a good design choice. This commit moves it into the Metaslab.
This commit is contained in:
committed by
Matthew Parkinson
parent
e7dce55f19
commit
59edf294d0
@@ -110,6 +110,17 @@ namespace snmalloc
|
||||
#endif
|
||||
}
|
||||
|
||||
/**
|
||||
* Nulls the previous pointer
|
||||
*
|
||||
* The Meta-slab uses nullptr in prev to mean that it is not part of a
|
||||
* size class list.
|
||||
**/
|
||||
void null_prev()
|
||||
{
|
||||
prev = nullptr;
|
||||
}
|
||||
|
||||
SNMALLOC_FAST_PATH CDLLNode* get_prev()
|
||||
{
|
||||
return prev;
|
||||
|
||||
Reference in New Issue
Block a user