aboutsummaryrefslogtreecommitdiffstats
path: root/vpp/vpp-api/api.c
AgeCommit message (Expand)AuthorFilesLines
2016-12-01Add vxlan-bypass feature to IP4 forwarding pathJohn Lo1-0/+24
2016-11-30Enabling AES-GCM-128 with 16B ICV supportRadu Nicolau1-2/+36
2016-11-30VXLAN multicast dst (remote) address supportEyal Bari1-21/+13
2016-11-30Start spliting vpe.api into logically related piecesDave Barach1-166/+1
2016-11-23dpdk: remove rte_mbuf modifications at many places in the codeDamjan Marion1-0/+4
2016-11-22GRE tests and fixesNeale Ranns1-1/+1
2016-11-22Fix coverity warnings, VPP-486Dave Barach1-10/+15
2016-11-22Fix issues reported by coverityPavel Kotucek1-1/+5
2016-11-21Add client-side msg_name_and_crc -> msg_index tableDave Barach1-19/+21
2016-11-17Fix VPP-132: leave IPv4 addresses in network byte order when sending.Matthew Smith1-1/+1
2016-11-17feature: API/CLI to enable/disable feature per interfacePavel Kotucek1-1/+42
2016-11-17Put address in top bytes for the nexthop in vl_api_fib_path_t (VPP-532)Steven1-42/+33
2016-11-16VPP-521: Classify API enhancement to redirect traffic to pre-defined VRFSteve Shin1-10/+23
2016-11-15span: add feature (rx only) (VPP-185)Pavel Kotucek1-0/+46
2016-11-15Dump routes (VPP-500)Steven1-5/+366
2016-11-14Add support for multi FIB DHCPv6 ProxyWojciech Dec1-4/+0
2016-11-11feature: convert all feature nodes to new feature infraDamjan Marion1-66/+8
2016-11-10VXLAN tunnel encap forwarding optimization with FIB 2.0John Lo1-2/+3
2016-11-04VPP-524: Add support to API to dump IPsec SPDsMatthew Smith1-1/+78
2016-11-03Adding Sequence Number - Per Packet Counter(PPC) support for iOAM6.AkshayaNadahalli1-1/+2
2016-11-01config: rename ip_config_main_t to vnet_feature_config_main_t-1/+3
2016-10-14Add macro for sending large data structures to API clientsFlorin Coras1-3/+18
2016-10-12Fix coverity warnings, VPP-486Dave Barach1-0/+8
2016-10-12VPP-362 Implement dumping of LISP adjacenciesFilip Tehlar1-1/+83
2016-10-10ipfix: add classification nodes for flow statistics (VPP-204)Juraj Sloboda1-1/+71
2016-10-07VPP-395 Add udp-punt node(s) and APIAlexander Popovsky (apopovsk)1-2/+23
2016-10-07VPP-466: PG pg_create_interface API returns wrong interface indexPavel Kotucek1-2/+3
2016-10-05Fix sw_interface_set_unnumbered API for FIB2.0Igor Mikhailov (imichail)1-4/+4
2016-10-04VPP-355: add PBB (802.1ah) tag rewritePavel Kotucek1-1/+38
2016-10-03L2 over LISP and GRE (VPP-457)-27/+41
2016-09-30VPP-450 Fix adding LISP adjacencies via CLIFilip Tehlar1-5/+5
2016-09-28DPDK HQoS: Enable Hierarchical Scheduler in VPPJasvinder Singh1-2/+142
2016-09-27LISP Source/Dest control plane support, VPP-197Florin Coras1-0/+28
2016-09-21A Protocol Independent Hierarchical FIB (VPP-352)Neale Ranns1-586/+261
2016-09-20VPP-189: fix coverity issue in api_format.cFilip Tehlar1-0/+2
2016-09-19Add support for transparent ethernet bridging to GREDavid Hotham1-0/+2
2016-09-13VPP-376: Refactor LISP dump API + VATFilip Tehlar1-38/+88
2016-09-07Fix bugs in IPFIX code discovered by coverityJuraj Sloboda1-12/+9
2016-09-07VPP-204 Rework and finish IPFIX implementationJuraj Sloboda1-14/+207
2016-09-06Move iOAM Trace as a pluginVengada Govindan1-38/+11
2016-09-02Add in-message cli_request/cli_reply APIOle Troan1-0/+57
2016-08-31VPP-369 Add an L2 output classification featureDave Barach1-3/+12
2016-08-31VPP-358: Add IPv6 ND Event Notification and TerminationJohn Lo1-27/+209
2016-08-31VPP-240: delete subinterfacePavel Kotucek1-1/+13
/span> "Garbage callback called..."); if (clib_cpu_time_now () % 3) { fformat (stdout, "collecting garbage...\n"); CV (clib_cuckoo_garbage_collect) (h); } else { fformat (stdout, "ignoring for now...\n"); } } static clib_error_t * test_cuckoo (test_main_t * tm) { int i; uword *p; uword total_searches; f64 before, delta; CVT (clib_cuckoo) * h; CVT (clib_cuckoo_kv) kv; h = &tm->hash; CV (clib_cuckoo_init) (h, "test", tm->nbuckets, cb, NULL); fformat (stdout, "Pick %lld unique %s keys...\n", tm->nitems, tm->non_random_keys ? "non-random" : "random"); for (i = 0; i < tm->nitems; i++) { u64 rndkey; if (tm->non_random_keys == 0) { again: rndkey = random_u64 (&tm->seed); p = hash_get (tm->key_hash, rndkey); if (p) goto again; } else rndkey = (u64) (i + 1) << 16; hash_set (tm->key_hash, rndkey, i + 1); vec_add1 (tm->keys, rndkey); } fformat (stdout, "Add items...\n"); for (i = 0; i < tm->nitems; i++) { kv.key = tm->keys[i]; kv.value = i + 1; CV (clib_cuckoo_add_del) (h, &kv, 1 /* is_add */ ); if (tm->verbose > 1) { fformat (stdout, "--------------------\n"); fformat (stdout, "After adding key %llu value %lld...\n", tm->keys[i], (u64) (i + 1)); fformat (stdout, "%U", CV (format_cuckoo), h, 2 /* very verbose */ ); } CVT (clib_cuckoo_kv) kv2; int rv = CV (clib_cuckoo_search) (h, &kv, &kv2); ASSERT (CLIB_CUCKOO_ERROR_SUCCESS == rv); } fformat (stdout, "%U", CV (format_cuckoo), h, 0 /* very verbose */ ); fformat (stdout, "Search for items %d times...\n", tm->search_iter); before = clib_time_now (&tm->clib_time); do_search (tm, h); delta = clib_time_now (&tm->clib_time) - before; total_searches = (uword) tm->search_iter * (uword) tm->nitems; if (delta > 0) fformat (stdout, "%.f searches per second\n", ((f64) total_searches) / delta); fformat (stdout, "%lld searches in %.6f seconds\n", total_searches, delta); #if 0 int j; fformat (stdout, "Standard E-hash search for items %d times...\n", tm->search_iter); before = clib_time_now (&tm->clib_time); for (j = 0; j < tm->search_iter; j++) { for (i = 0; i < tm->nitems; i++) { p = hash_get (tm->key_hash, tm->keys[i]); if (p == 0 || p[0] != (uword) (i + 1)) clib_warning ("ugh, couldn't find %lld\n", tm->keys[i]); } } delta = clib_time_now (&tm->clib_time) - before; total_searches = (uword) tm->search_iter * (uword) tm->nitems; fformat (stdout, "%lld searches in %.6f seconds\n", total_searches, delta); if (delta > 0) fformat (stdout, "%.f searches per second\n", ((f64) total_searches) / delta); #endif fformat (stdout, "Delete items...\n"); for (i = 0; i < tm->nitems; i++) { int j; int rv; kv.key = tm->keys[i]; kv.value = (u64) (i + 1); rv = CV (clib_cuckoo_add_del) (h, &kv, 0 /* is_add */ ); if (rv < 0) clib_warning ("delete key %lld not ok but should be", tm->keys[i]); if (tm->careful_delete_tests) { for (j = 0; j < tm->nitems; j++) { kv.key = tm->keys[j]; rv = CV (clib_cuckoo_search) (h, &kv, &kv); if (j <= i && rv >= 0) { clib_warning ("i %d j %d search ok but should not be, value %lld", i, j, kv.value); } if (j > i && rv < 0) { clib_warning ("i %d j %d search not ok but should be", i, j); } } } } fformat (stdout, "After deletions, should be empty...\n"); fformat (stdout, "%U", CV (format_cuckoo), h, 0 /* very verbose */ ); return 0; } clib_error_t * test_cuckoo_main (test_main_t * tm) { unformat_input_t *i = tm->input; clib_error_t *error; while (unformat_check_input (i) != UNFORMAT_END_OF_INPUT) { if (unformat (i, "seed %u", &tm->seed)) ; else if (unformat (i, "nbuckets %d", &tm->nbuckets)) ; else if (unformat (i, "non-random-keys")) tm->non_random_keys = 1; else if (unformat (i, "nitems %d", &tm->nitems)) ; else if (unformat (i, "careful %d", &tm->careful_delete_tests)) ; else if (unformat (i, "verbose %d", &tm->verbose)) ; else if (unformat (i, "search %d", &tm->search_iter)) ; else if (unformat (i, "verbose")) tm->verbose = 1; else return clib_error_return (0, "unknown input '%U'", format_unformat_error, i); } error = test_cuckoo (tm); return error; } #ifdef CLIB_UNIX int main (int argc, char *argv[]) { unformat_input_t i; clib_error_t *error; test_main_t *tm = &test_main; clib_mem_init (0, 3ULL << 30); tm->input = &i; tm->seed = 0xdeaddabe; tm->nbuckets = 2; tm->nitems = 100000; tm->verbose = 1; tm->search_iter = 10000; tm->careful_delete_tests = 0; tm->key_hash = hash_create (0, sizeof (uword)); clib_time_init (&tm->clib_time); unformat_init_command_line (&i, argv); error = test_cuckoo_main (tm); unformat_free (&i); if (error) { clib_error_report (error); return 1; } return 0; } #endif /* CLIB_UNIX */ /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */