typedefstruct {
boolean fixed_len; /* true if the records have fixed length */ int rec_len; /* the length of the records - used when fixed_len true */ int num_blocks; /* The number of blocks or data - initially 1 */ int **table_block; /* for the records themselves - table_block[i] (i>=0) *pointstostartof(i+1)-thblockofrecords.
*/ int **table_data_ptr; /* table_data_ptr[i] points to the address *intable_datawherethei-threcordbegins. *Forspacereasons,thisisonlyusedwhen *fixed_lenisfalse-forfixed_lentrue,itcan *becalculated.Thelengthoftherecordis *calculatedbyusingtable_data_ptr[i+1]. *(exceptwhenrecordi+1startsanewblock)
*/ int *current_ptr; /* The location in table_data where the current *recordforinvestigationbegins.
*/ int num_recs; /* The current number of records. */ int maxrecs; /* the largest number of records allowed + 1 *-canbeincreaseddynamicallyifexceeded.
*/ int num_recs_inc; /* The initial value of num_recs, and the increment *whenitisincreased.
*/ int block_space; /* space occupied in current block */ int tot_space; /* total space occupied in all blocks */ int space_inc; /* The initial value of allocated space for records, *andtheincrementwhenitisincreased- *thesizeofeachblockofdata
*/ int recs_per_block; /* When fixed_len true, the number of recs in each block *equalto(maxspace/rec_len).
*/ int modulus; /* used as modulus when calculating hash values */ int hash_values; /* the maximum number of hash_values - *modulus*hash_values*2mustnotexceedMAXINT.
*/ int *first_rec; /* first_rec[i] (for 0 <= i < hash_values) *isthenumberofthefirstrecordwithhashedvaluei.
*/ int *next_rec; /* next_rec[i] is the number of a record with the same *hashedvalueasrecordnumberi- *or-1,iftherearenofurthersuchrecords. *notethatnext_recrequiresspacemaxrecs.
*/ int *block_start_rec; /* block_start_rec[i] is the number of the record which *startsattable_block[i]-onlyneededwhenfixed_len *isfalse.
*/ int *block_last_len; /* The length of the last record in table_block[i]. *onlyneededwhenfixed_lenisfalse.
*/
/* NOTE: Record numbering starts at 0, and record number 0 is always the *recordinwhichallentriesare0. *Forvariablelengthrecords,thiswillhavelength0.
*/
} hash_table;
typedefstruct {
boolean fixed_len; /* true if the records have fixed length */ int rec_len; /* the length of the records - used when fixed_len true */ int num_blocks; /* The number of blocks or data - initially 1 */ unsignedshort **table_block; /* for the records themselves - table_block[i] (i>=0) *pointstostartof(i+1)-thblockofrecords.
*/ unsignedshort **table_data_ptr; /* table_data_ptr[i] points to the address *intable_datawherethei-threcordbegins. *Forspacereasons,thisisonlyusedwhen *fixed_lenisfalse-forfixed_lentrue,itcan *becalculated.Thelengthoftherecordis *calculatedbyusingtable_data_ptr[i+1]. *(exceptwhenrecordi+1startsanewblock)
*/ unsignedshort *current_ptr; /* The location in table_data where the current *recordforinvestigationbegins.
*/ int num_recs; /* The current number of records. */ int maxrecs; /* the largest number of records allowed + 1 *-canbeincreaseddynamicallyifexceeded.
*/ int num_recs_inc; /* The initial value of num_recs, and the increment *whenitisincreased.
*/ int block_space; /* space occupied in current block */ int tot_space; /* total space occupied in all blocks */ int space_inc; /* The initial value of allocated space for records, *andtheincrementwhenitisincreased- *thesizeofeachblockofdata
*/ int recs_per_block; /* When fixed_len true, the number of recs in each block *equalto(maxspace/rec_len).
*/ int modulus; /* used as modulus when calculating hash values */ int hash_values; /* the maximum number of hash_values - *modulus*hash_values*2mustnotexceedMAXINT.
*/ int *first_rec; /* first_rec[i] (for 0 <= i < hash_values) *isthenumberofthefirstrecordwithhashedvaluei.
*/ int *next_rec; /* next_rec[i] is the number of a record with the same *hashedvalueasrecordnumberi- *or-1,iftherearenofurthersuchrecords. *notethatnext_recrequiresspacemaxrecs.
*/ int *block_start_rec; /* block_start_rec[i] is the number of the record which *startsattable_block[i]-onlyneededwhenfixed_len *isfalse.
*/ int *block_last_len; /* The length of the last record in table_block[i]. *onlyneededwhenfixed_lenisfalse.
*/
/* NOTE: Record numbering starts at 0, and record number 0 is always the *recordinwhichallentriesare0. *Forvariablelengthrecords,thiswillhavelength0.
*/
} short_hash_table;
typedefstruct {
boolean fixed_len; /* true if the records have fixed length */ int rec_len; /* the length of the records - used when fixed_len true */ int num_blocks; /* The number of blocks or data - initially 1 */ char **table_block; /* for the records themselves - table_block[i] (i>=0) *pointstostartof(i+1)-thblockofrecords.
*/ char **table_data_ptr; /* table_data_ptr[i] points to the address *intable_datawherethei-threcordbegins. *Forspacereasons,thisisonlyusedwhen *fixed_lenisfalse-forfixed_lentrue,itcan *becalculated.Thelengthoftherecordis *calculatedbyusingtable_data_ptr[i+1]. *(exceptwhenrecordi+1startsanewblock)
*/ char *current_ptr; /* The location in table_data where the current *recordforinvestigationbegins.
*/ int num_recs; /* The current number of records. */ int maxrecs; /* the largest number of records allowed + 1 *-canbeincreaseddynamicallyifexceeded.
*/ int num_recs_inc; /* The initial value of num_recs, and the increment *whenitisincreased.
*/ int block_space; /* space occupied in current block */ int tot_space; /* total space occupied in all blocks */ int space_inc; /* The initial value of allocated space for records, *andtheincrementwhenitisincreased- *thesizeofeachblockofdata
*/ int recs_per_block; /* When fixed_len true, the number of recs in each block *equalto(maxspace/rec_len).
*/ int modulus; /* used as modulus when calculating hash values */ int hash_values; /* the maximum number of hash_values - *modulus*hash_values*2mustnotexceedMAXINT.
*/ int *first_rec; /* first_rec[i] (for 0 <= i < hash_values) *isthenumberofthefirstrecordwithhashedvaluei.
*/ int *next_rec; /* next_rec[i] is the number of a record with the same *hashedvalueasrecordnumberi- *or-1,iftherearenofurthersuchrecords. *notethatnext_recrequiresspacemaxrecs.
*/ int *block_start_rec; /* block_start_rec[i] is the number of the record which *startsattable_block[i]-onlyneededwhenfixed_len *isfalse.
*/ int *block_last_len; /* The length of the last record in table_block[i]. *onlyneededwhenfixed_lenisfalse.
*/
/* NOTE: Record numbering starts at 0, and record number 0 is always the *recordinwhichallentriesare0. *Forvariablelengthrecords,thiswillhavelength0.
*/
} char_hash_table;
typedefstruct {
boolean fixed_len; /* true if the records have fixed length */ int rec_len; /* the length of the records - used when fixed_len true */ int num_blocks; /* The number of blocks or data - initially 1 */
gen **table_block; /* for the records themselves - table_block[i] (i>=0) *pointstostartof(i+1)-thblockofrecords.
*/
gen **table_data_ptr; /* table_data_ptr[i] points to the address *intable_datawherethei-threcordbegins. *Forspacereasons,thisisonlyusedwhen *fixed_lenisfalse-forfixed_lentrue,itcan *becalculated.Thelengthoftherecordis *calculatedbyusingtable_data_ptr[i+1]. *(exceptwhenrecordi+1startsanewblock)
*/
gen *current_ptr; /* The location in table_data where the current *recordforinvestigationbegins.
*/ int num_recs; /* The current number of records. */ int maxrecs; /* the largest number of records allowed + 1 *-canbeincreaseddynamicallyifexceeded.
*/ int num_recs_inc; /* The initial value of num_recs, and the increment *whenitisincreased.
*/ int block_space; /* space occupied in current block */ int tot_space; /* total space occupied in all blocks */ int space_inc; /* The initial value of allocated space for records, *andtheincrementwhenitisincreased- *thesizeofeachblockofdata
*/ int recs_per_block; /* When fixed_len true, the number of recs in each block *equalto(maxspace/rec_len).
*/ int modulus; /* used as modulus when calculating hash values */ int hash_values; /* the maximum number of hash_values - *modulus*hash_values*2mustnotexceedMAXINT.
*/ int *first_rec; /* first_rec[i] (for 0 <= i < hash_values) *isthenumberofthefirstrecordwithhashedvaluei.
*/ int *next_rec; /* next_rec[i] is the number of a record with the same *hashedvalueasrecordnumberi- *or-1,iftherearenofurthersuchrecords. *notethatnext_recrequiresspacemaxrecs.
*/ int *block_start_rec; /* block_start_rec[i] is the number of the record which *startsattable_block[i]-onlyneededwhenfixed_len *isfalse.
*/ int *block_last_len; /* The length of the last record in table_block[i]. *onlyneededwhenfixed_lenisfalse.
*/
/* NOTE: Record numbering starts at 0, and record number 0 is always the *recordinwhichallentriesare0. *Forvariablelengthrecords,thiswillhavelength0.
*/
} gen_hash_table;
externvoid hash_init(hash_table *htptr, boolean fixed, int len, int num_recs_inc, int space_inc); externvoid hash_clear(hash_table *htptr); externint hash_locate(hash_table *htptr, int reclen); externint hash_rec_len(hash_table *htptr, int n); externint *hash_rec(hash_table *htptr, int n);
externvoid short_hash_init(short_hash_table *htptr, boolean fixed, int len, int num_recs_inc, int space_inc); externvoid short_hash_clear(short_hash_table *htptr); externint short_hash_locate(short_hash_table *htptr, int reclen); externint short_hash_rec_len(short_hash_table *htptr, int n); externunsignedshort *short_hash_rec(short_hash_table *htptr, int n);
externvoid gen_hash_init(gen_hash_table *htptr, boolean fixed, int len, int num_recs_inc, int space_inc); externvoid gen_hash_clear(gen_hash_table *htptr); externint gen_hash_locate(gen_hash_table *htptr, int reclen); externint gen_hash_rec_len(gen_hash_table *htptr, int n); extern gen *gen_hash_rec(gen_hash_table *htptr, int n);
#endif
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.14 Sekunden
(vorverarbeitet am 2026-06-17)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.