|
Classes |
struct | shuffle_candidate |
Defines |
#define | boolean int |
#define | true 1 |
#define | false 0 |
#define | log_errors true |
#define | trace_io false |
#define | fn_log_f printf |
#define | hash_value(b, limit) ((((int)b.block) + b.segment) % limit) |
#define | buddy_window 32 |
#define | mark_modified(f, bufix) f->buffer_pool.buffer[bufix].modified = true |
#define | delete_threshold 1 |
#define | feasible_move(a, b, c) ( (a<=keyspace_lc) && (b<=keyspace_lc) && (c<=keyspace_lc) ) |
#define | kf6_keyrec_lc(a) version_err |
#define | kf6_set_bof(a) version_err |
#define | kf6_set_eof(a) version_err |
#define | kf6_get_ptr(a, b, c, d) version_err |
#define | kf6_put_ptr(a, b, c, d) version_err |
#define | kf6_delete_ptr(a, b, c) version_err |
#define | kf6_next_ptr(a, b, c, d, e) version_err |
#define | kf6_prev_ptr(a, b, c, d, e) version_err |
#define | kf6_get_rec(a, b, c, d, e, f) version_err |
#define | kf6_put_rec(a, b, c, d, e) version_err |
#define | kf6_delete_rec(a, b, c) version_err |
#define | kf6_next_rec(a, b, c, d, e, f, g) version_err |
#define | kf6_prev_rec(a, b, c, d, e, f, g) version_err |
#define | kf6_get_subrec(a, b, c, d, e, f, g) version_err |
#define | kf6_open_key(a, b, c, d) version_err |
#define | kf6_create_key(a, b, c) version_err |
#define | kf6_create_key_ld(a, b, c, d) version_err |
#define | kf6_close_key(a) version_err |
Functions |
boolean | allocate_rec () |
void | replace_max_key () |
void | deallocate_rec () |
void | check_ix_block_compression () |
void | update_index () |
void | index_delete () |
void | split_block () |
FILE * | file_index () |
void | print_index_type (FILE *list, int index_type) |
int | compressed_int_lc (unsigned char buf[]) |
int | uncompress_key_lc (UINT16 *key_lc, unsigned char p[]) |
int | uncompress_UINT16 (UINT16 *i, unsigned char p[]) |
int | uncompress_UINT32 (UINT32 *i, unsigned char p[]) |
int | uncompress_UINT64 (UINT64 *i, unsigned char p[]) |
int | compress_UINT32 (UINT32 i, unsigned char *ptr) |
int | compress_UINT64 (UINT64 i, unsigned char *ptr) |
int | UINT32_lc_if_compressed (UINT32 i) |
int | UINT64_lc_if_compressed (UINT64 i) |
unsigned | allocation_lc (unsigned lc, unsigned unit) |
unsigned | rec_allocation_lc (unsigned lc) |
boolean | error_is_fatal (UINT32 error_code) |
void | set_err (struct fcb *f, UINT32 err) |
void | set_error (struct fcb *f, int err, char caption[]) |
void | set_error1 (struct fcb *f, int err, char caption[], int code) |
void | set_error2 (struct fcb *f, int err, char caption[], int code1, int code2) |
boolean | check_fcb (struct fcb *f) |
boolean | set_up (struct fcb *f, unsigned char key[], unsigned key_lc, struct key *k) |
boolean | gt_n_pntr (struct leveln_pntr p1, struct leveln_pntr p2) |
int | pntr_sc (struct ix_block *b, int ix) |
int | pack0_ptr (struct fcb *f, struct ix_block *b, level0_pntr *p) |
int | unpack0_lc (struct fcb *f, struct ix_block *b, int ix) |
int | unpack0_ptr (struct fcb *f, struct ix_block *b, int ix, level0_pntr *p) |
int | unpack0_ptr_and_rec (struct fcb *f, buffer_t *buf, int ix, level0_pntr *p, unsigned char rec[], unsigned *rec_lc, unsigned max_rec_lc) |
int | level0_pntr_lc (struct fcb *f, level0_pntr *p) |
int | leveln_pntr_lc (struct leveln_pntr *p) |
int | levelx_pntr_lc (struct fcb *f, levelx_pntr *p, int level) |
int | packn_ptr (struct ix_block *b, struct leveln_pntr *p) |
int | unpackn_lc (struct ix_block *b, int ix) |
int | unpackn_ptr (struct ix_block *b, int ix, struct leveln_pntr *p) |
int | nth_pntr_lc (struct fcb *f, struct ix_block *b, int ix) |
int | copy_ptr (struct fcb *f, struct ix_block *b, int ix, struct ix_block *b1) |
boolean | eq_key (struct key *k1, struct key *k2) |
void | copy_key (struct key *from, struct key *to) |
int | key_entry_lc (struct ix_block *b, int ix) |
int | get_nth_key (struct ix_block *b, struct key *k, int n) |
int | get_nth_key_and_pntr (struct fcb *f, struct ix_block *b, struct key *k, int n, levelx_pntr *p) |
void | get_max_key (struct ix_block *b, struct key *k) |
void | init_file_name (struct fcb *f, char id[]) |
void | build_segment_name (struct fcb *f, unsigned segment, char name[]) |
void | byte_swap_UINT16s (unsigned char s[], int cnt) |
void | byte_swap_UINT32 (unsigned char n[]) |
void | byte_swap_UINT64 (unsigned char n[]) |
unsigned char | read_byte (struct fcb *f, FILE *file) |
UINT16 | read_UINT16 (struct fcb *f, FILE *file) |
UINT32 | read_UINT32 (struct fcb *f, FILE *file) |
UINT64 | read_UINT64 (struct fcb *f, FILE *file) |
boolean | read_fib (struct fcb *f, char id[], boolean byte_swapping_required, boolean read_only) |
void | write_UINT16 (struct fcb *f, FILE *file, UINT16 *i) |
void | write_UINT16s (struct fcb *f, FILE *file, unsigned char s[], unsigned int cnt) |
void | write_UINT32 (struct fcb *f, FILE *file, UINT32 i) |
void | write_UINT64 (struct fcb *f, FILE *file, UINT64 i) |
void | write_fib (struct fcb *f) |
void | read_page (struct fcb *f, struct leveln_pntr p, block_type_t *buf) |
void | get_page (struct fcb *f, struct leveln_pntr blk, block_type_t *buf) |
void | write_page (struct fcb *f, struct leveln_pntr p, block_type_t *buf) |
int | vacate_file_index (struct fcb *f) |
void | open_segment (struct fcb *f, unsigned segment, int ix) |
int | file_ix (struct fcb *f, unsigned segment) |
FILE * | file_index (struct fcb *f, unsigned segment) |
void | set_position (struct fcb *f, int index, struct leveln_pntr b, int ix) |
void | reset_ages (struct fcb *f) |
int | search_hash_chain (struct fcb *f, struct leveln_pntr block) |
void | hash_chain_insert (struct fcb *f, int bufix) |
void | hash_chain_remove (struct fcb *f, int bufix) |
void | make_buffer_youngest (struct fcb *f, int bufix) |
void | init_buffer_hash_fields (struct fcb *f, int i, struct leveln_pntr *b) |
void | initialize_buffer (struct fcb *f, int bufix, struct leveln_pntr *contents) |
int | write_block_and_buddies (struct fcb *f, int bufix) |
int | vacate_oldest_buffer (struct fcb *f, struct leveln_pntr *b) |
void | copy_index_block (struct ix_block *b1, struct ix_block *b2) |
void | set_empty_block_prefix (struct ix_block *b, struct key *prefix, unsigned prefix_lc) |
void | initialize_index_block (struct ix_block *b, int index, unsigned lvl, struct key *prefix, unsigned prefix_lc) |
int | get_index (struct fcb *f, struct leveln_pntr b) |
int | find_prefix_lc (struct key *k1, struct key *k2) |
int | block_prefix_lc (struct ix_block *b) |
unsigned | ix_pool_lc (struct ix_block *b) |
unsigned | ix_entry_lc (struct fcb *f, struct key *k, levelx_pntr *p, unsigned prefix_lc, int level) |
unsigned | ix_entries_lc (struct fcb *f, struct ix_block *b, int start, int cnt, unsigned prefix_lc) |
unsigned | new_chars_in_use (struct ix_block *b, int prefix_lc) |
int | ix_pool_lc_after_insert (struct fcb *f, struct ix_block *b, struct key *k, levelx_pntr *p, int ix, unsigned *new_prefix_lc) |
int | ix_pool_lc_after_replace (struct fcb *f, struct ix_block *b, struct key *k, levelx_pntr *p, int ix, unsigned *new_prefix_lc) |
int | ix_pool_lc_after_change (struct fcb *f, struct ix_block *b, struct key *k, levelx_pntr *p, int ix, unsigned *new_prefix_lc, boolean insert) |
int | compare_key (unsigned char k[], UINT32 klc, struct ix_block *b, int ix) |
int | search_block (struct fcb *f, int bufix, struct key *k, boolean *found) |
leveln_pntr | search_index (struct fcb *f, int index, UINT32 stop_lvl, struct key *k) |
leveln_pntr | parent_block (struct fcb *f, int bufix, struct key *k) |
void | set_block_shift (struct fcb *f) |
boolean | machine_is_little_endian () |
void | init_key (struct fcb *f, char id[], int lc) |
void | insert_rec (struct fcb *f, char r[], level0_pntr *p) |
void | lock_buffer (f, bufix) struct fcb *f |
Variables |
int | read_cnt |
level0_pntr | null0_ptr |
leveln_pntr | nulln_ptr = {max_segment,0} |
int | power_of_two [20] |
int | bufix |