Boost logo

Boost :

Subject: Re: [boost] [block_ptr] Region Based Memory Managment
From: Phil Bouchard (philippeb8_at_[hidden])
Date: 2014-12-27 13:45:43


On 12/24/2014 05:05 PM, Phil Bouchard wrote:
> On 12/23/2014 11:57 PM, Phil Bouchard wrote:
>> Greetings Boost,
>>
>> I was talking to Filip Pizlo from the Webkit community and he pointed
>> out that block_ptr is what we call a Region Based Memory Manager:
>> http://en.wikipedia.org/wiki/Region-based_memory_management
>>
>> If we consider the worse case scenario, the sets (regions) can be
>> unified to create a really big set. So to make block_ptr hybrid we
>> could add a "garbage collection layer" to detect cycles inside a set
>> that is not yet destructed. This function could be called explicitly
>> whenever some memory usage quota is reached. It's very easy to
>> implement.
>
> I meant to add a simple mark-sweep pass on top of block_ptr.

The only issue of adding a mark-sweep pass is I think we'll need to add
another pointer to the block_ptr class in order to chain the pointers so
that sizeof(block_ptr<T>) == sizeof(void *) * 3.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk