Re: Bitwise sweeping

Dave Mason <[email protected]> Mon, 10 Jan 2011 14:14:07 -0500
Newsgroups gmane.comp.programming.garbage-collection.general
Message-ID <[email protected]>
On Jan 9, 2011, at 19:30, Jon Harrop wrote:

> The first cache line in the region
> stores 512 allocated bits (= 1 cache line) that indicate which of the 512
> blocks in the remainder of the region have been allocated. The second cache
> line contains a similar bitvector for mark bits that are zero

It would require testing, but it might be better to only use 1/2 of a cache line, so that sweep operations only load one line.  As Hans indicated, that cache line is going to get hit on a lot depending on your region size... e.g. if it's the same size as your L1 cache, it will get pounded.

../Dave