diff options
author | Matias Elo <matias.elo@nokia.com> | 2022-10-20 17:41:51 +0300 |
---|---|---|
committer | Matias Elo <matias.elo@nokia.com> | 2022-10-25 14:22:24 +0300 |
commit | 22316428d6e6e2dc37b449360f44e9a3eec21f2e (patch) | |
tree | e4ec14176afdd878fb35a850e77d03e85a81dcd2 /test | |
parent | 70522f66b9654b9b6757fc902b2410fa55c6ed02 (diff) |
test: bench_packet: print actual function names
Print actual API function names in output. Removed empty dummy test.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/performance/odp_bench_packet.c | 434 |
1 files changed, 173 insertions, 261 deletions
diff --git a/test/performance/odp_bench_packet.c b/test/performance/odp_bench_packet.c index 0d2eefdc0..a9b5f201c 100644 --- a/test/performance/odp_bench_packet.c +++ b/test/performance/odp_bench_packet.c @@ -1,4 +1,5 @@ /* Copyright (c) 2017-2018, Linaro Limited + * Copyright (c) 2022, Nokia * All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause @@ -182,7 +183,7 @@ static void run_indef(args_t *args, int idx) desc = args->bench[idx].desc != NULL ? args->bench[idx].desc : args->bench[idx].name; - printf("Running %s() indefinitely\n", desc); + printf("Running odp_%s test indefinitely\n", desc); while (!odp_atomic_load_u32(&gbl_args->exit_thread)) { int ret; @@ -270,7 +271,7 @@ static int run_benchmarks(void *arg) TEST_REPEAT_COUNT); results[j][i] = cycles; - printf("%-30s: %8.1f\n", desc, cycles); + printf("odp_%-26s: %8.1f\n", desc, cycles); j++; k = 0; @@ -290,7 +291,7 @@ static int run_benchmarks(void *arg) printf("----------"); for (i = 0; i < gbl_args->num_bench; i++) { - printf("\n[%02d] %-30s", i + 1, args->bench[i].desc != NULL ? + printf("\n[%02d] odp_%-26s", i + 1, args->bench[i].desc != NULL ? args->bench[i].desc : args->bench[i].name); for (j = 0; j < num_sizes; j++) @@ -516,17 +517,7 @@ static void free_packets_twice(void) odp_packet_free_multi(gbl_args->pkt2_tbl, TEST_REPEAT_COUNT); } -static int bench_empty(void) -{ - int i; - - for (i = 0; i < TEST_REPEAT_COUNT; i++) - gbl_args->output_tbl[i] = i; - - return i; -} - -static int bench_packet_alloc(void) +static int packet_alloc(void) { int i; @@ -541,7 +532,7 @@ static int bench_packet_alloc(void) return i; } -static int bench_packet_alloc_multi(void) +static int packet_alloc_multi(void) { int i; int pkts = 0; @@ -554,7 +545,7 @@ static int bench_packet_alloc_multi(void) return pkts; } -static int bench_packet_free(void) +static int packet_free(void) { int i; @@ -564,7 +555,7 @@ static int bench_packet_free(void) return i; } -static int bench_packet_free_multi(void) +static int packet_free_multi(void) { int i; @@ -577,7 +568,7 @@ static int bench_packet_free_multi(void) return i; } -static int bench_packet_free_sp(void) +static int packet_free_sp(void) { int i; @@ -590,7 +581,7 @@ static int bench_packet_free_sp(void) return i; } -static int bench_packet_alloc_free(void) +static int packet_alloc_free(void) { int i; @@ -604,7 +595,7 @@ static int bench_packet_alloc_free(void) return i; } -static int bench_packet_alloc_free_multi(void) +static int packet_alloc_free_multi(void) { int i; int pkts; @@ -622,7 +613,7 @@ static int bench_packet_alloc_free_multi(void) return i; } -static int bench_packet_reset(void) +static int packet_reset(void) { int i; int ret = 0; @@ -633,7 +624,7 @@ static int bench_packet_reset(void) return !ret; } -static int bench_packet_from_event(void) +static int packet_from_event(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -644,7 +635,7 @@ static int bench_packet_from_event(void) return i; } -static int bench_packet_from_event_multi(void) +static int packet_from_event_multi(void) { int i; @@ -658,7 +649,7 @@ static int bench_packet_from_event_multi(void) return i; } -static int bench_packet_to_event(void) +static int packet_to_event(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -669,7 +660,7 @@ static int bench_packet_to_event(void) return i; } -static int bench_packet_to_event_multi(void) +static int packet_to_event_multi(void) { int i; @@ -683,7 +674,7 @@ static int bench_packet_to_event_multi(void) return i; } -static int bench_packet_head(void) +static int packet_head(void) { int i; @@ -693,7 +684,7 @@ static int bench_packet_head(void) return i; } -static int bench_packet_buf_len(void) +static int packet_buf_len(void) { int i; uint32_t ret = 0; @@ -704,7 +695,7 @@ static int bench_packet_buf_len(void) return ret; } -static int bench_packet_data(void) +static int packet_data(void) { int i; @@ -714,7 +705,7 @@ static int bench_packet_data(void) return i; } -static int bench_packet_data_seg_len(void) +static int packet_data_seg_len(void) { odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; uint32_t *output_tbl = gbl_args->output_tbl; @@ -726,7 +717,7 @@ static int bench_packet_data_seg_len(void) return i; } -static int bench_packet_seg_len(void) +static int packet_seg_len(void) { int i; uint32_t ret = 0; @@ -737,7 +728,7 @@ static int bench_packet_seg_len(void) return ret; } -static int bench_packet_len(void) +static int packet_len(void) { int i; uint32_t ret = 0; @@ -748,7 +739,7 @@ static int bench_packet_len(void) return ret; } -static int bench_packet_headroom(void) +static int packet_headroom(void) { int i; uint32_t ret = 0; @@ -759,7 +750,7 @@ static int bench_packet_headroom(void) return i + ret; } -static int bench_packet_tailroom(void) +static int packet_tailroom(void) { int i; uint32_t ret = 0; @@ -770,7 +761,7 @@ static int bench_packet_tailroom(void) return i + ret; } -static int bench_packet_tail(void) +static int packet_tail(void) { int i; @@ -780,7 +771,7 @@ static int bench_packet_tail(void) return i; } -static int bench_packet_offset(void) +static int packet_offset(void) { int i; uint32_t offset = gbl_args->pkt.len / 2; @@ -791,7 +782,7 @@ static int bench_packet_offset(void) return i; } -static int bench_packet_prefetch(void) +static int packet_prefetch(void) { int i; @@ -801,7 +792,7 @@ static int bench_packet_prefetch(void) return i; } -static int bench_packet_push_head(void) +static int packet_push_head(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -813,7 +804,7 @@ static int bench_packet_push_head(void) return i; } -static int bench_packet_pull_head(void) +static int packet_pull_head(void) { int i; uint32_t len = gbl_args->pkt.seg_len - 1; @@ -825,7 +816,7 @@ static int bench_packet_pull_head(void) return i; } -static int bench_packet_push_tail(void) +static int packet_push_tail(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -837,7 +828,7 @@ static int bench_packet_push_tail(void) return i; } -static int bench_packet_pull_tail(void) +static int packet_pull_tail(void) { int i; uint32_t len = gbl_args->pkt.seg_len - 1; @@ -849,7 +840,7 @@ static int bench_packet_pull_tail(void) return i; } -static int bench_packet_extend_head(void) +static int packet_extend_head(void) { int i; int ret = 0; @@ -864,7 +855,7 @@ static int bench_packet_extend_head(void) return ret >= 0; } -static int bench_packet_trunc_head(void) +static int packet_trunc_head(void) { int i; int ret = 0; @@ -879,7 +870,7 @@ static int bench_packet_trunc_head(void) return ret >= 0; } -static int bench_packet_extend_tail(void) +static int packet_extend_tail(void) { int i; int ret = 0; @@ -894,7 +885,7 @@ static int bench_packet_extend_tail(void) return ret >= 0; } -static int bench_packet_trunc_tail(void) +static int packet_trunc_tail(void) { int i; int ret = 0; @@ -909,7 +900,7 @@ static int bench_packet_trunc_tail(void) return ret >= 0; } -static int bench_packet_add_data(void) +static int packet_add_data(void) { int i; int ret = 0; @@ -922,7 +913,7 @@ static int bench_packet_add_data(void) return ret >= 0; } -static int bench_packet_rem_data(void) +static int packet_rem_data(void) { int i; int ret = 0; @@ -935,7 +926,7 @@ static int bench_packet_rem_data(void) return ret >= 0; } -static int bench_packet_align(void) +static int packet_align(void) { int i; int ret = 0; @@ -947,7 +938,7 @@ static int bench_packet_align(void) return ret >= 0; } -static int bench_packet_is_segmented(void) +static int packet_is_segmented(void) { int i; uint32_t ret = 0; @@ -958,7 +949,7 @@ static int bench_packet_is_segmented(void) return (ret == 0) ? 1 : ret; } -static int bench_packet_num_segs(void) +static int packet_num_segs(void) { int i; uint32_t ret = 0; @@ -969,7 +960,7 @@ static int bench_packet_num_segs(void) return ret; } -static int bench_packet_first_seg(void) +static int packet_first_seg(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -980,7 +971,7 @@ static int bench_packet_first_seg(void) return i; } -static int bench_packet_last_seg(void) +static int packet_last_seg(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -991,7 +982,7 @@ static int bench_packet_last_seg(void) return i; } -static int bench_packet_next_seg(void) +static int packet_next_seg(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1003,7 +994,7 @@ static int bench_packet_next_seg(void) return i; } -static int bench_packet_seg_data(void) +static int packet_seg_data(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1015,7 +1006,7 @@ static int bench_packet_seg_data(void) return i; } -static int bench_packet_seg_data_len(void) +static int packet_seg_data_len(void) { int i; uint32_t ret = 0; @@ -1028,7 +1019,7 @@ static int bench_packet_seg_data_len(void) return ret; } -static int bench_packet_concat(void) +static int packet_concat(void) { int i; int ret = 0; @@ -1041,7 +1032,7 @@ static int bench_packet_concat(void) return ret >= 0; } -static int bench_packet_split(void) +static int packet_split(void) { int i; int ret = 0; @@ -1057,7 +1048,7 @@ static int bench_packet_split(void) return ret >= 0; } -static int bench_packet_copy(void) +static int packet_copy(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1069,7 +1060,7 @@ static int bench_packet_copy(void) return i; } -static int bench_packet_copy_part(void) +static int packet_copy_part(void) { int i; uint32_t len = gbl_args->pkt.len / 2; @@ -1082,7 +1073,7 @@ static int bench_packet_copy_part(void) return i; } -static int bench_packet_copy_to_mem(void) +static int packet_copy_to_mem(void) { int i; uint32_t ret = 0; @@ -1095,7 +1086,7 @@ static int bench_packet_copy_to_mem(void) return !ret; } -static int bench_packet_copy_from_mem(void) +static int packet_copy_from_mem(void) { int i; uint32_t ret = 0; @@ -1108,7 +1099,7 @@ static int bench_packet_copy_from_mem(void) return !ret; } -static int bench_packet_copy_from_pkt(void) +static int packet_copy_from_pkt(void) { int i; uint32_t ret = 0; @@ -1122,7 +1113,7 @@ static int bench_packet_copy_from_pkt(void) return !ret; } -static int bench_packet_copy_data(void) +static int packet_copy_data(void) { int i; uint32_t ret = 0; @@ -1135,7 +1126,7 @@ static int bench_packet_copy_data(void) return !ret; } -static int bench_packet_move_data(void) +static int packet_move_data(void) { int i; uint32_t ret = 0; @@ -1149,7 +1140,7 @@ static int bench_packet_move_data(void) return !ret; } -static int bench_packet_pool(void) +static int packet_pool(void) { int i; @@ -1159,7 +1150,7 @@ static int bench_packet_pool(void) return i; } -static int bench_packet_input(void) +static int packet_input(void) { int i; @@ -1169,7 +1160,7 @@ static int bench_packet_input(void) return i; } -static int bench_packet_input_index(void) +static int packet_input_index(void) { int i; int ret = 0; @@ -1180,7 +1171,7 @@ static int bench_packet_input_index(void) return (ret == 0) ? 1 : ret; } -static int bench_packet_user_ptr(void) +static int packet_user_ptr(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1191,7 +1182,7 @@ static int bench_packet_user_ptr(void) return i; } -static int bench_packet_user_ptr_set(void) +static int packet_user_ptr_set(void) { int i; @@ -1202,7 +1193,7 @@ static int bench_packet_user_ptr_set(void) return i; } -static int bench_packet_user_area(void) +static int packet_user_area(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1213,7 +1204,7 @@ static int bench_packet_user_area(void) return i; } -static int bench_packet_user_area_size(void) +static int packet_user_area_size(void) { int i; uint32_t ret = 0; @@ -1224,7 +1215,7 @@ static int bench_packet_user_area_size(void) return ret; } -static int bench_packet_l2_ptr(void) +static int packet_l2_ptr(void) { int i; @@ -1234,7 +1225,7 @@ static int bench_packet_l2_ptr(void) return i; } -static int bench_packet_l2_offset(void) +static int packet_l2_offset(void) { int i; int ret = 0; @@ -1245,7 +1236,7 @@ static int bench_packet_l2_offset(void) return ret >= 0; } -static int bench_packet_l2_offset_set(void) +static int packet_l2_offset_set(void) { int i; uint32_t ret = 0; @@ -1257,7 +1248,7 @@ static int bench_packet_l2_offset_set(void) return !ret; } -static int bench_packet_l3_ptr(void) +static int packet_l3_ptr(void) { int i; @@ -1267,7 +1258,7 @@ static int bench_packet_l3_ptr(void) return i; } -static int bench_packet_l3_offset(void) +static int packet_l3_offset(void) { int i; int ret = 0; @@ -1278,7 +1269,7 @@ static int bench_packet_l3_offset(void) return ret >= 0; } -static int bench_packet_l3_offset_set(void) +static int packet_l3_offset_set(void) { int i; uint32_t ret = 0; @@ -1290,7 +1281,7 @@ static int bench_packet_l3_offset_set(void) return !ret; } -static int bench_packet_l4_ptr(void) +static int packet_l4_ptr(void) { int i; @@ -1300,7 +1291,7 @@ static int bench_packet_l4_ptr(void) return i; } -static int bench_packet_l4_offset(void) +static int packet_l4_offset(void) { int i; int ret = 0; @@ -1311,7 +1302,7 @@ static int bench_packet_l4_offset(void) return ret >= 0; } -static int bench_packet_l4_offset_set(void) +static int packet_l4_offset_set(void) { int i; uint32_t ret = 0; @@ -1323,7 +1314,7 @@ static int bench_packet_l4_offset_set(void) return !ret; } -static int bench_packet_flow_hash(void) +static int packet_flow_hash(void) { int i; uint32_t ret = 0; @@ -1334,7 +1325,7 @@ static int bench_packet_flow_hash(void) return ret; } -static int bench_packet_flow_hash_set(void) +static int packet_flow_hash_set(void) { int i; @@ -1344,7 +1335,7 @@ static int bench_packet_flow_hash_set(void) return i; } -static int bench_packet_ts(void) +static int packet_ts(void) { int i; @@ -1354,7 +1345,7 @@ static int bench_packet_ts(void) return i; } -static int bench_packet_ts_set(void) +static int packet_ts_set(void) { int i; odp_time_t ts = odp_time_local(); @@ -1365,7 +1356,7 @@ static int bench_packet_ts_set(void) return i; } -static int bench_packet_ref_static(void) +static int packet_ref_static(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1377,7 +1368,7 @@ static int bench_packet_ref_static(void) return i; } -static int bench_packet_ref(void) +static int packet_ref(void) { int i; uint32_t offset = TEST_MIN_PKT_SIZE / 2; @@ -1390,7 +1381,7 @@ static int bench_packet_ref(void) return i; } -static int bench_packet_ref_pkt(void) +static int packet_ref_pkt(void) { int i; uint32_t offset = TEST_MIN_PKT_SIZE / 2; @@ -1403,7 +1394,7 @@ static int bench_packet_ref_pkt(void) return i; } -static int bench_packet_has_ref(void) +static int packet_has_ref(void) { int i; uint32_t ret = 0; @@ -1415,7 +1406,7 @@ static int bench_packet_has_ref(void) return i + ret; } -static int bench_packet_subtype(void) +static int packet_subtype(void) { int i; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1426,7 +1417,7 @@ static int bench_packet_subtype(void) return i; } -static int bench_packet_parse(void) +static int packet_parse(void) { odp_packet_parse_param_t param; odp_packet_t *pkt_tbl = gbl_args->pkt_tbl; @@ -1446,7 +1437,7 @@ static int bench_packet_parse(void) return !ret; } -static int bench_packet_parse_multi(void) +static int packet_parse_multi(void) { int burst_size = gbl_args->appl.burst_size; int ret = 0; @@ -1561,176 +1552,97 @@ static void print_info(char *progname, appl_args_t *appl_args ODP_UNUSED) * Test functions */ bench_info_t test_suite[] = { - BENCH_INFO(bench_empty, NULL, NULL, NULL), - BENCH_INFO(bench_packet_alloc, NULL, free_packets, NULL), - BENCH_INFO(bench_packet_alloc_multi, NULL, free_packets_multi, - NULL), - BENCH_INFO(bench_packet_free, create_packets, NULL, NULL), - BENCH_INFO(bench_packet_free_multi, alloc_packets_multi, NULL, - NULL), - BENCH_INFO(bench_packet_free_sp, alloc_packets_multi, NULL, - NULL), - BENCH_INFO(bench_packet_alloc_free, NULL, NULL, NULL), - BENCH_INFO(bench_packet_alloc_free_multi, NULL, NULL, NULL), - BENCH_INFO(bench_packet_reset, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_from_event, create_events, free_packets, - NULL), - BENCH_INFO(bench_packet_from_event_multi, create_events_multi, - free_packets_multi, NULL), - BENCH_INFO(bench_packet_to_event, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_to_event_multi, alloc_packets_multi, - free_packets_multi, NULL), - BENCH_INFO(bench_packet_head, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_buf_len, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_data, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_data_seg_len, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_seg_len, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_len, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_headroom, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_tailroom, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_tail, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_offset, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_prefetch, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_push_head, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_pull_head, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_push_tail, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_pull_tail, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_extend_head, alloc_packets_half, - free_packets, NULL), - BENCH_INFO(bench_packet_trunc_head, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_extend_tail, alloc_packets_half, - free_packets, NULL), - BENCH_INFO(bench_packet_trunc_tail, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_add_data, alloc_packets_half, - free_packets, NULL), - BENCH_INFO(bench_packet_rem_data, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_align, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_is_segmented, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_num_segs, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_first_seg, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_last_seg, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_next_seg, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_seg_data, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_seg_data_len, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_concat, alloc_concat_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_split, create_packets, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_copy, create_packets, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_copy_part, create_packets, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_copy_to_mem, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_copy_from_mem, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_copy_from_pkt, alloc_packets_twice, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_copy_data, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_move_data, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_pool, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_input, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_input_index, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_user_ptr, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_user_ptr_set, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_user_area, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_user_area_size, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_l2_ptr, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_l2_offset, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_l2_offset_set, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_l3_ptr, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_l3_offset, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_l3_offset_set, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_l4_ptr, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_l4_offset, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_l4_offset_set, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_flow_hash, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_flow_hash_set, create_packets, - free_packets, NULL), - BENCH_INFO(bench_packet_ts, create_packets, free_packets, NULL), - BENCH_INFO(bench_packet_ts_set, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_ref_static, create_packets, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_ref, create_packets, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_ref_pkt, alloc_packets_twice, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_has_ref, alloc_ref_packets, - free_packets_twice, NULL), - BENCH_INFO(bench_packet_subtype, create_packets, free_packets, - NULL), - BENCH_INFO(bench_packet_parse, alloc_parse_packets_ipv4_tcp, - free_packets, "bench_packet_parse_ipv4_tcp"), - BENCH_INFO(bench_packet_parse, alloc_parse_packets_ipv4_udp, - free_packets, "bench_packet_parse_ipv4_udp"), - BENCH_INFO(bench_packet_parse, alloc_parse_packets_ipv6_tcp, - free_packets, "bench_packet_parse_ipv6_tcp"), - BENCH_INFO(bench_packet_parse, alloc_parse_packets_ipv6_udp, - free_packets, "bench_packet_parse_ipv6_udp"), - BENCH_INFO(bench_packet_parse_multi, - alloc_parse_packets_multi_ipv4_tcp, - free_packets_multi, - "bench_packet_parse_multi_ipv4_tcp"), - BENCH_INFO(bench_packet_parse_multi, - alloc_parse_packets_multi_ipv4_udp, - free_packets_multi, - "bench_packet_parse_multi_ipv4_udp"), - BENCH_INFO(bench_packet_parse_multi, - alloc_parse_packets_multi_ipv6_tcp, - free_packets_multi, - "bench_packet_parse_multi_ipv6_tcp"), - BENCH_INFO(bench_packet_parse_multi, - alloc_parse_packets_multi_ipv6_udp, - free_packets_multi, - "bench_packet_parse_multi_ipv6_udp"), + BENCH_INFO(packet_alloc, NULL, free_packets, NULL), + BENCH_INFO(packet_alloc_multi, NULL, free_packets_multi, NULL), + BENCH_INFO(packet_free, create_packets, NULL, NULL), + BENCH_INFO(packet_free_multi, alloc_packets_multi, NULL, NULL), + BENCH_INFO(packet_free_sp, alloc_packets_multi, NULL, NULL), + BENCH_INFO(packet_alloc_free, NULL, NULL, NULL), + BENCH_INFO(packet_alloc_free_multi, NULL, NULL, NULL), + BENCH_INFO(packet_reset, create_packets, free_packets, NULL), + BENCH_INFO(packet_from_event, create_events, free_packets, NULL), + BENCH_INFO(packet_from_event_multi, create_events_multi, free_packets_multi, NULL), + BENCH_INFO(packet_to_event, create_packets, free_packets, NULL), + BENCH_INFO(packet_to_event_multi, alloc_packets_multi, free_packets_multi, NULL), + BENCH_INFO(packet_head, create_packets, free_packets, NULL), + BENCH_INFO(packet_buf_len, create_packets, free_packets, NULL), + BENCH_INFO(packet_data, create_packets, free_packets, NULL), + BENCH_INFO(packet_data_seg_len, create_packets, free_packets, NULL), + BENCH_INFO(packet_seg_len, create_packets, free_packets, NULL), + BENCH_INFO(packet_len, create_packets, free_packets, NULL), + BENCH_INFO(packet_headroom, create_packets, free_packets, NULL), + BENCH_INFO(packet_tailroom, create_packets, free_packets, NULL), + BENCH_INFO(packet_tail, create_packets, free_packets, NULL), + BENCH_INFO(packet_offset, create_packets, free_packets, NULL), + BENCH_INFO(packet_prefetch, create_packets, free_packets, NULL), + BENCH_INFO(packet_push_head, create_packets, free_packets, NULL), + BENCH_INFO(packet_pull_head, create_packets, free_packets, NULL), + BENCH_INFO(packet_push_tail, create_packets, free_packets, NULL), + BENCH_INFO(packet_pull_tail, create_packets, free_packets, NULL), + BENCH_INFO(packet_extend_head, alloc_packets_half, free_packets, NULL), + BENCH_INFO(packet_trunc_head, create_packets, free_packets, NULL), + BENCH_INFO(packet_extend_tail, alloc_packets_half, free_packets, NULL), + BENCH_INFO(packet_trunc_tail, create_packets, free_packets, NULL), + BENCH_INFO(packet_add_data, alloc_packets_half, free_packets, NULL), + BENCH_INFO(packet_rem_data, create_packets, free_packets, NULL), + BENCH_INFO(packet_align, create_packets, free_packets, NULL), + BENCH_INFO(packet_is_segmented, create_packets, free_packets, NULL), + BENCH_INFO(packet_num_segs, create_packets, free_packets, NULL), + BENCH_INFO(packet_first_seg, create_packets, free_packets, NULL), + BENCH_INFO(packet_last_seg, create_packets, free_packets, NULL), + BENCH_INFO(packet_next_seg, create_packets, free_packets, NULL), + BENCH_INFO(packet_seg_data, create_packets, free_packets, NULL), + BENCH_INFO(packet_seg_data_len, create_packets, free_packets, NULL), + BENCH_INFO(packet_concat, alloc_concat_packets, free_packets, NULL), + BENCH_INFO(packet_split, create_packets, free_packets_twice, NULL), + BENCH_INFO(packet_copy, create_packets, free_packets_twice, NULL), + BENCH_INFO(packet_copy_part, create_packets, free_packets_twice, NULL), + BENCH_INFO(packet_copy_to_mem, create_packets, free_packets, NULL), + BENCH_INFO(packet_copy_from_mem, create_packets, free_packets, NULL), + BENCH_INFO(packet_copy_from_pkt, alloc_packets_twice, free_packets_twice, NULL), + BENCH_INFO(packet_copy_data, create_packets, free_packets, NULL), + BENCH_INFO(packet_move_data, create_packets, free_packets, NULL), + BENCH_INFO(packet_pool, create_packets, free_packets, NULL), + BENCH_INFO(packet_input, create_packets, free_packets, NULL), + BENCH_INFO(packet_input_index, create_packets, free_packets, NULL), + BENCH_INFO(packet_user_ptr, create_packets, free_packets, NULL), + BENCH_INFO(packet_user_ptr_set, create_packets, free_packets, NULL), + BENCH_INFO(packet_user_area, create_packets, free_packets, NULL), + BENCH_INFO(packet_user_area_size, create_packets, free_packets, NULL), + BENCH_INFO(packet_l2_ptr, create_packets, free_packets, NULL), + BENCH_INFO(packet_l2_offset, create_packets, free_packets, NULL), + BENCH_INFO(packet_l2_offset_set, create_packets, free_packets, NULL), + BENCH_INFO(packet_l3_ptr, create_packets, free_packets, NULL), + BENCH_INFO(packet_l3_offset, create_packets, free_packets, NULL), + BENCH_INFO(packet_l3_offset_set, create_packets, free_packets, NULL), + BENCH_INFO(packet_l4_ptr, create_packets, free_packets, NULL), + BENCH_INFO(packet_l4_offset, create_packets, free_packets, NULL), + BENCH_INFO(packet_l4_offset_set, create_packets, free_packets, NULL), + BENCH_INFO(packet_flow_hash, create_packets, free_packets, NULL), + BENCH_INFO(packet_flow_hash_set, create_packets, free_packets, NULL), + BENCH_INFO(packet_ts, create_packets, free_packets, NULL), + BENCH_INFO(packet_ts_set, create_packets, free_packets, NULL), + BENCH_INFO(packet_ref_static, create_packets, free_packets_twice, NULL), + BENCH_INFO(packet_ref, create_packets, free_packets_twice, NULL), + BENCH_INFO(packet_ref_pkt, alloc_packets_twice, free_packets_twice, NULL), + BENCH_INFO(packet_has_ref, alloc_ref_packets, free_packets_twice, NULL), + BENCH_INFO(packet_subtype, create_packets, free_packets, NULL), + BENCH_INFO(packet_parse, alloc_parse_packets_ipv4_tcp, free_packets, + "packet_parse ipv4/tcp"), + BENCH_INFO(packet_parse, alloc_parse_packets_ipv4_udp, free_packets, + "packet_parse ipv4/udp"), + BENCH_INFO(packet_parse, alloc_parse_packets_ipv6_tcp, free_packets, + "packet_parse ipv6/tcp"), + BENCH_INFO(packet_parse, alloc_parse_packets_ipv6_udp, free_packets, + "packet_parse ipv6/udp"), + BENCH_INFO(packet_parse_multi, alloc_parse_packets_multi_ipv4_tcp, free_packets_multi, + "packet_parse_multi ipv4/tcp"), + BENCH_INFO(packet_parse_multi, alloc_parse_packets_multi_ipv4_udp, free_packets_multi, + "packet_parse_multi ipv4/udp"), + BENCH_INFO(packet_parse_multi, alloc_parse_packets_multi_ipv6_tcp, free_packets_multi, + "packet_parse_multi ipv6/tcp"), + BENCH_INFO(packet_parse_multi, alloc_parse_packets_multi_ipv6_udp, free_packets_multi, + "packet_parse_multi ipv6/udp"), }; /** @@ -1844,7 +1756,7 @@ int main(int argc, char *argv[]) odp_pool_param_init(¶ms); params.pkt.seg_len = PKT_POOL_SEG_LEN; /* Using packet length as twice the TEST_MAX_PKT_SIZE as some - * test cases (bench_packet_ref_pkt) might allocate a bigger + * test cases (packet_ref_pkt) might allocate a bigger * packet than TEST_MAX_PKT_SIZE. */ params.pkt.len = 2 * TEST_MAX_PKT_SIZE; |