From 439b3ecbcf8af074624ebe9f81f6db0ef1654f31 Mon Sep 17 00:00:00 2001 From: fc_botelho Date: Mon, 24 Jan 2005 19:11:08 +0000 Subject: [PATCH] The algorithms and hash functions were put in alphabetical order --- src/cmph_types.h | 6 +++--- src/main.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/cmph_types.h b/src/cmph_types.h index 6e07879..077fb60 100644 --- a/src/cmph_types.h +++ b/src/cmph_types.h @@ -5,10 +5,10 @@ typedef unsigned char cmph_uint8; typedef unsigned short cmph_uint16; typedef unsigned int cmph_uint32; -typedef enum { CMPH_HASH_JENKINS, CMPH_HASH_DJB2, CMPH_HASH_SDBM, CMPH_HASH_FNV, - CMPH_HASH_GLIB, CMPH_HASH_PJW, CMPH_HASH_COUNT } CMPH_HASH; +typedef enum { CMPH_HASH_DJB2, CMPH_HASH_FNV, CMPH_HASH_GLIB, CMPH_HASH_JENKINS, + CMPH_HASH_PJW, CMPH_HASH_SDBM, CMPH_HASH_COUNT } CMPH_HASH; extern const char *cmph_hash_names[]; -typedef enum { CMPH_CZECH, CMPH_BMZ, CMPH_COUNT } CMPH_ALGO; /* included -- Fabiano */ +typedef enum { CMPH_BMZ, CMPH_CZECH, CMPH_COUNT } CMPH_ALGO; /* included -- Fabiano */ extern const char *cmph_names[]; #endif diff --git a/src/main.c b/src/main.c index 21ab419..97e73a6 100644 --- a/src/main.c +++ b/src/main.c @@ -18,12 +18,12 @@ void usage(const char *prg) { - fprintf(stderr, "usage: %s [-v] [-h] [-V] [-k nkeys] [-g [-c value][-s seed] ] [-m file.mph] [-a algorithm] keysfile\n", prg); + fprintf(stderr, "usage: %s [-v] [-h] [-V] [-k nkeys] [-f hash_function] [-g [-c value][-s seed] ] [-m file.mph] [-a algorithm] keysfile\n", prg); } void usage_long(const char *prg) { cmph_uint32 i; - fprintf(stderr, "usage: %s [-v] [-h] [-V] [-k] [-g [-s seed] ] [-m file.mph] [-a algorithm] keysfile\n", prg); + fprintf(stderr, "usage: %s [-v] [-h] [-V] [-k nkeys] [-f hash_function] [-g [-c value][-s seed] ] [-m file.mph] [-a algorithm] keysfile\n", prg); fprintf(stderr, "Minimum perfect hashing tool\n\n"); fprintf(stderr, " -h\t print this help message\n"); fprintf(stderr, " -c\t c value that determines the number of vertices in the graph\n");