what space efficiency to expect -
10-26-2006
, 04:46 PM
hello,
I'm writing the program in C, and so using the C libraries for berkely
db 4.1.25 that come with RHES3
what i want to store is this.
the key is
char key[32]
the data i want to store
struct theData {
unsigned short int D1,
unsigned int D2,
unsigned short int D3[250],
unsigned short int D4[250],
unsigned short int D5[250],
unsigned short int D6[250],
unsigned short int D7[250],
};
I think the size of theData struct will be 2506 bytes and the key is 32
bytes. my so thats 400,000 entries per GB.
I was reading some articles about aligning your data, can someone tell
me if any alignment is required?
would aligning data somehow reduce the amount of padding required?
Cheers, |