Re: [Algorithms] memory pool algorithms
Brought to you by:
vexxed72
|
From: Alen L. <ale...@cr...> - 2009-04-23 19:54:31
|
Thursday, April 23, 2009, 6:34:16 PM, Paul wrote: > Thanks Alen, I *think* this is the same solution that Jeremiha posted and > looks like it will suit my purposes nicely Yes, I think it is the same. My ISP was down, so I didn't see Jeremiah has posted already before me. :) I like the neat trick of joining the used and free arrays into one. Also note the difference in the address-to-index mapping. That mapping is necessary if the objects are going to be referenced from the outside, because the indices change at deallocation. If you are going to reference and delete the objects only through iteration, then you don't need it. Cheers, Alen |