Wasted too much space for minimum element count. Now minimum elements in vektor is 16, it grows and shrinks by a factor of 4 and a shrinking hysteresis of a factor of 5

master
Dirk Engling 2007-02-01 16:06:17 +00:00
parent e12ac60dea
commit f545ad8774
1 changed files with 4 additions and 4 deletions

View File

@ -38,10 +38,10 @@ typedef time_t ot_time;
#define OT_POOLS_TIMEOUT 300
#define NOW (time(NULL)/OT_POOLS_TIMEOUT)
#define OT_VECTOR_MIN_MEMBERS 128
#define OT_VECTOR_GROW_RATIO 2
#define OT_VECTOR_SHRINK_THRESH 3
#define OT_VECTOR_SHRINK_RATIO 2
#define OT_VECTOR_MIN_MEMBERS 16
#define OT_VECTOR_GROW_RATIO 4
#define OT_VECTOR_SHRINK_THRESH 5
#define OT_VECTOR_SHRINK_RATIO 4
typedef struct {
void *data;
size_t size;