summaryrefslogtreecommitdiffstats
path: root/src/vlib/node_funcs.h
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2022-04-11 18:41:49 +0200
committerFlorin Coras <florin.coras@gmail.com>2022-04-12 22:40:52 +0000
commite4fa1d2f6b8721318c0f104f2615588b5d4e0441 (patch)
tree70d33a24bae0b9aa993fe6e03960e2b135accb70 /src/vlib/node_funcs.h
parent65e770d895b13a6e5c73d13f436872ea626e47e3 (diff)
vppinfra: vector perf improvements
Type: improvement Change-Id: I37c187af80c21b8fb1ab15af112527a837e0df9e Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vlib/node_funcs.h')
-rw-r--r--src/vlib/node_funcs.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/vlib/node_funcs.h b/src/vlib/node_funcs.h
index df8ec7c40e6..5b4d2a4be29 100644
--- a/src/vlib/node_funcs.h
+++ b/src/vlib/node_funcs.h
@@ -836,6 +836,7 @@ vlib_process_signal_event_helper (vlib_node_main_t * nm,
{
uword p_flags, add_to_pending, delete_from_wheel;
u8 *data_to_be_written_by_caller;
+ vec_attr_t va = { .elt_sz = n_data_elt_bytes };
ASSERT (n->type == VLIB_NODE_TYPE_PROCESS);
@@ -856,9 +857,7 @@ vlib_process_signal_event_helper (vlib_node_main_t * nm,
l = vec_len (data_vec);
- data_vec =
- _vec_realloc (data_vec, l + n_data_elts, n_data_elt_bytes,
- /* header_bytes */ 0, /* data_align */ 0, /* heap */ 0);
+ data_vec = _vec_realloc_internal (data_vec, l + n_data_elts, &va);
p->pending_event_data_by_type_index[t] = data_vec;
data_to_be_written_by_caller = data_vec + l * n_data_elt_bytes;