SegHeap Class Reference

A segregated-fits collection of (homogeneous) heaps. More...

#include <segheap.h>


Detailed Description

A segregated-fits collection of (homogeneous) heaps.

Author:
Emery Berger

Note that one extra heap is used for objects that are "too big".

Parameters:
NumBins The number of bins (subheaps).
getSizeClass Function to compute size class from size.
getClassMaxSize Function to compute the largest size for a given size class.
LittleHeap The subheap class.
BigHeap The parent class, used for "big" objects.

Example:
int myFunc (size_t sz); // The size-to-class function.
size_t myFunc2 (int); // The class-to-size function.

// The heap. Use freelists for these small objects,
// but defer to malloc for large objects.

SegHeap<4, myFunc, myFunc2, freelistHeap<mallocHeap>, mallocHeap> mySegHeap;


The documentation for this class was generated from the following file:
Generated on Tue Aug 2 11:51:28 2011 for Galois by  doxygen 1.6.3