TKRZW_DBM_PERF(1)

πŸ“¦
version 1.0.32 Β· 3 versions
, in epel 10, fedora 43

πŸ’– TKRZW_DBM_PERF πŸ’–

okay bestie, so this is tkrzw_dbm_perf, a whole manual page for tkrzw_dbm_perf 1.0.32 β€” a lil tool that ships with the Tkrzw crew and lives in your terminal under User Commands. it's giving "benchmark goblin" and honestly? iconic. let's get into it. πŸŽ€


✨ NAME ✨

tkrzw_dbm_perf β€” the manual page for tkrzw_dbm_perf 1.0.32, bestie. that's the whole name section, no notes. πŸ’…


🌸 DESCRIPTION 🌸

tkrzw_dbm_perf: Performance checker of DBM implementations of Tkrzw β€” like, it's the vibe check for your databases. it puts DBM implementations through their paces and tells you how fast they're moving. no cap. πŸ¦‹

🫢 Usage 🫢

tkrzw_dbm_perf sequence [options]
: Checks setting/getting/removing performance in sequence.
tkrzw_dbm_perf parallel [options]
: Checks setting/getting/removing performance in parallel.
tkrzw_dbm_perf wicked [options]
: Checks consistency with various operations.
tkrzw_dbm_perf index [options]
: Checks performance of on-memory indexing.

four subcommands, four whole personalities. pick your fighter. πŸ’œ


πŸ‘‘ Common options πŸ‘‘

these ones show up for everybody. the shared wardrobe, if you will. πŸ’–

  • --dbm impl β€” the name of a DBM implementation. your choices are: auto, hash, tree, skip, tiny, baby, cache, stdhash, stdtree, poly, shard. (default: auto)
  • --iter num β€” the number of iterations. (default: 10000)
  • --size num β€” the size of each record value. (default: 8)
  • --threads num β€” the number of threads. (default: 1)
  • --random_seed num β€” the random seed, or negative for real RNG. (default: 0)
  • --verbose β€” prints verbose reports. she's chatty and we love that. πŸ—£οΈ
  • --path path β€” the path of the file to write or read.
  • --file impl β€” the name of a file implementation: std, mmap-para, mmap-atom, pos-para, pos-atom. (default: mmap-para)
  • --no_wait β€” fails if the file is locked by another process. no patience energy.
  • --no_lock β€” omits file locking.
  • --sync_hard β€” synchronizes the file physically when closing.
  • --alloc_init num β€” the initial allocation size. (default: 1048576)
  • --alloc_inc num β€” the allocation increment factor. (default: 2.0)
  • --block_size num β€” the block size of the positional access file. (default: 1)
  • --direct_io β€” enables the direct I/O option of the positional access file.
  • --sync_io β€” enables the synchronous I/O option of the positional access file.
  • --padding β€” enables padding at the end of the file.
  • --pagecache β€” enables the mini page cache in the process.
  • --ulog str β€” sets the prefix of update log files.

πŸŽ€ Options for the sequence subcommand πŸŽ€

the orderly one. one thing at a time, main character energy. ⭐

  • --random_key β€” uses random keys rather than sequential ones.
  • --random_value β€” uses random length values rather than fixed ones.
  • --set_only β€” does only setting.
  • --get_only β€” does only getting.
  • --remove_only β€” does only removing.
  • --validate β€” validates records.
  • --copy str β€” copies the database file.

🌈 Options for the parallel subcommand 🌈

multithreaded chaos, but make it controlled. πŸ”₯

  • --random_key β€” uses random keys rather than sequential ones.
  • --random_value β€” uses random length values rather than fixed ones.
  • --keys β€” the number of unique keys.
  • --rebuild β€” rebuilds the database occasionally.
  • --sleep num β€” the duration to sleep between iterations. (default: 0)
  • --validate β€” validates records.

πŸ’€ Options for the wicked subcommand πŸ’€

this one is literally named wicked. it does the most, on purpose, to check consistency. πŸ™ˆ

  • --iterator β€” uses iterators occasionally.
  • --clear β€” clears the database occasionally.
  • --rebuild β€” rebuilds the database occasionally.
  • --validate β€” validates records.

🧚 Options for the index subcommand 🧚

on-memory indexing speedrun, let's go. ✨

  • --type expr β€” the types of the key and value of the index: file, mem, n2n, n2s, s2n, s2s, str, file. (default: file)
  • --random_key β€” uses random keys rather than sequential ones.
  • --random_value β€” uses random length values rather than fixed ones.

πŸ“ Options for HashDBM πŸ“

  • --append β€” uses the appending mode rather than the in-place mode.
  • --record_crc num β€” the record CRC mode: -1, 0, 8, 16, 32. (default: 0 or -1)
  • --record_comp str β€” the record compression mode: default, none, zlib, zstd, lz4, lzma, rc4, aes. (default: none or default)
  • --offset_width num β€” the width to represent the offset of records. (default: 4)
  • --align_pow num β€” sets the power to align records. (default: 3)
  • --buckets num β€” sets the number of buckets for hashing. (default: 1048583)
  • --fbp_cap num β€” sets the capacity of the free block pool. (default: 2048)
  • --min_read_size num β€” sets the minimum reading size to read a record. (default: -1)
  • --cache_buckets β€” caches the hash buckets on memory.
  • --cipher_key str β€” sets the encryption key for cipher compressors. (default: empty)

πŸ’œ Options for TreeDBM and FileIndex πŸ’œ

same energy as above, but with tree-level extras. 🌸

  • --append β€” uses the appending mode rather than the in-place mode.
  • --record_crc num β€” the record CRC mode: -1, 0, 8, 16, 32. (default: 0 or -1)
  • --record_comp str β€” the record compression mode: default, none, zlib, zstd, lz4, lzma, rc4, aes. (default: none or default)
  • --offset_width num β€” the width to represent the offset of records. (default: 4)
  • --align_pow num β€” sets the power to align records. (default: 10)
  • --buckets num β€” sets the number of buckets for hashing. (default: 131101)
  • --fbp_cap num β€” sets the capacity of the free block pool. (default: 2048)
  • --min_read_size num β€” sets the minimum reading size to read a record. (default: -1)
  • --cache_buckets β€” caches the hash buckets on memory.
  • --cipher_key str β€” sets the encryption key for cipher compressors. (default: empty)
  • --max_page_size num β€” sets the maximum size of a page. (default: 8130)
  • --max_branches num β€” sets the maximum number of branches of inner nodes. (default: 256)
  • --max_cached_pages num β€” sets the maximum number of cached pages. (default: 10000)
  • --page_update_write β€” writes updated pages immediately.

⭐ Options for SkipDBM ⭐

skip list supremacy, honestly. 🌈

  • --offset_width num β€” the width to represent the offset of records. (default: 4)
  • --step_unit num β€” sets the step unit of the skip list. (default: 4)
  • --max_level num β€” sets the maximum level of the skip list. (default: 14)
  • --sort_mem_size num β€” sets the memory size used for sorting. (default: 268435456)
  • --insert_in_order β€” inserts records in ascending order of the key.
  • --max_cached_records num β€” sets the number of cached records (default: 65536)
  • --reducer func β€” sets the reducer: none, first, second, last, concat, total. (default: none)

πŸŽ€ Options for TinyDBM and StdHashDBM πŸŽ€

short and sweet, one single flag, she's efficient. πŸ’–

  • --buckets num β€” sets the number of buckets for hashing. (default: 1048583)

πŸ¦‹ Options for CacheDBM πŸ¦‹

  • --cap_rec_num num β€” sets the maximum number of records. (default: 1048576)
  • --cap_memsize num β€” sets the total memory size to use.

πŸ”₯ Options for PolyDBM and ShardDBM πŸ”₯

  • --params str β€” sets the parameters in "key=value,key=value" format.

lowkey a whole lot of flags, highkey worth it. go benchmark something and tell me the numbers. 🫢

and that's the page, bestie!! this was tkrzw_dbm_perf 1.0.32 from January 2025 β€” mwah, thank you for coming to my ted talk, drink some water, and may all your iterations be fast. πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from