diff options
| author | rsc <devnull@localhost> | 2004-03-12 18:28:14 +0000 |
|---|---|---|
| committer | rsc <devnull@localhost> | 2004-03-12 18:28:14 +0000 |
| commit | 9ffbb5adcaeec878d3b6db0f8b1f654e839b4689 (patch) | |
| tree | bfd7abf95e87e3b97f3ae2e0ae3bf59c30839cc7 /src/cmd/venti/dat.h | |
| parent | 7c5190d2c854128fb607289e9d83379e522c7090 (diff) | |
| download | plan9port-9ffbb5adcaeec878d3b6db0f8b1f654e839b4689.tar.gz plan9port-9ffbb5adcaeec878d3b6db0f8b1f654e839b4689.zip | |
Checkpoint.
Add disk caching code and first draft of fractional index.
Diffstat (limited to 'src/cmd/venti/dat.h')
| -rw-r--r-- | src/cmd/venti/dat.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/cmd/venti/dat.h b/src/cmd/venti/dat.h index d6d7d1b0..49c8b38b 100644 --- a/src/cmd/venti/dat.h +++ b/src/cmd/venti/dat.h @@ -79,7 +79,8 @@ enum ArenaPartVersion = 3, ArenaVersion = 4, - IndexVersion = 1, + IndexVersion1 = 1, + IndexVersion2 = 2, ISectVersion = 1, /* @@ -116,11 +117,14 @@ enum MaxClumpBlocks = (VtMaxLumpSize + ClumpSize + (1 << ABlockLog) - 1) >> ABlockLog, /* - * dirty flags + * dirty flags - order controls disk write order */ DirtyArena = 1, + DirtyIndexSplit, DirtyIndex, + DirtyIndexBitmap, DirtyArenaCib, + DirtyMax, VentiZZZZZZZZ }; @@ -367,6 +371,11 @@ struct Index u32int buckets; /* last bucket used in disk hash table */ u32int blocksize; u32int tabsize; /* max. bytes in index config */ + u32int bitblocks; + u32int maxdepth; + u32int bitkeylog; + u32int bitkeymask; + int mapalloc; /* first arena to check when adding a lump */ Arena **arenas; /* arenas in the mapping */ ISect **sects; /* sections which hold the buckets */ @@ -440,7 +449,7 @@ struct IEntry struct IBucket { u16int n; /* number of active indices */ - u32int next; /* overflow bucket */ + u32int depth; /* depth in version 2 (was overflow in v1) */ u8int *data; }; |
