New upstream version 16.11.9
[deb_dpdk.git] / app / test / test_hash_perf.c
index 9d53c14..b0514b1 100644 (file)
@@ -49,7 +49,8 @@
 #define MAX_ENTRIES (1 << 19)
 #define KEYS_TO_ADD (MAX_ENTRIES * 3 / 4) /* 75% table utilization */
 #define NUM_LOOKUPS (KEYS_TO_ADD * 5) /* Loop among keys added, several times */
-#define BUCKET_SIZE 4
+/* BUCKET_SIZE should be same as RTE_HASH_BUCKET_ENTRIES in rte_hash library */
+#define BUCKET_SIZE 8
 #define NUM_BUCKETS (MAX_ENTRIES / BUCKET_SIZE)
 #define MAX_KEYSIZE 64
 #define NUM_KEYSIZES 10
@@ -656,8 +657,4 @@ test_hash_perf(void)
        return 0;
 }
 
-static struct test_command hash_perf_cmd = {
-               .command = "hash_perf_autotest",
-               .callback = test_hash_perf,
-};
-REGISTER_TEST_COMMAND(hash_perf_cmd);
+REGISTER_TEST_COMMAND(hash_perf_autotest, test_hash_perf);