diff options
author | Florin Coras <fcoras@cisco.com> | 2017-06-19 12:26:09 -0400 |
---|---|---|
committer | Dave Barach <openvpp@barachs.net> | 2017-06-22 16:55:03 +0000 |
commit | f6359c8cace5b73a813e5f4e3d1bc28f7752fcdf (patch) | |
tree | 38aa2a4dca15fb49c8c6ed967f1fd50d522926cc /src/vnet/session/node.c | |
parent | 5be2d073ceb695104fd84bce592cb588f8aaaa66 (diff) |
Improve svm fifo and tcp tx path performance (VPP-846)
- multiarch on svm fifo
- avoid ip lookup on tx
Change-Id: Iab0d85204a710979417bca1d692cc47877131203
Signed-off-by: Florin Coras <fcoras@cisco.com>
Signed-off-by: Dave Barach <dbarach@cisco.com>
Diffstat (limited to 'src/vnet/session/node.c')
-rw-r--r-- | src/vnet/session/node.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/vnet/session/node.c b/src/vnet/session/node.c index c0ab1bf096f..b24f5fd994d 100644 --- a/src/vnet/session/node.c +++ b/src/vnet/session/node.c @@ -248,6 +248,11 @@ session_tx_fifo_read_and_snd_i (vlib_main_t * vm, vlib_node_runtime_t * node, ASSERT (bi0); _vec_len (smm->tx_buffers[thread_index]) = n_bufs; + /* usual speculation, or the enqueue_x1 macro will barf */ + to_next[0] = bi0; + to_next += 1; + n_left_to_next -= 1; + b0 = vlib_get_buffer (vm, bi0); b0->error = 0; b0->flags = VLIB_BUFFER_TOTAL_LENGTH_VALID @@ -255,10 +260,6 @@ session_tx_fifo_read_and_snd_i (vlib_main_t * vm, vlib_node_runtime_t * node, b0->current_data = 0; b0->total_length_not_including_first_buffer = 0; - /* RX on the local interface. tx in default fib */ - vnet_buffer (b0)->sw_if_index[VLIB_RX] = 0; - vnet_buffer (b0)->sw_if_index[VLIB_TX] = (u32) ~ 0; - len_to_deq0 = clib_min (left_to_snd0, deq_per_buf); data0 = vlib_buffer_make_headroom (b0, MAX_HDRS_LEN); @@ -307,10 +308,6 @@ session_tx_fifo_read_and_snd_i (vlib_main_t * vm, vlib_node_runtime_t * node, })); /* *INDENT-ON* */ - /* usual speculation, or the enqueue_x1 macro will barf */ - to_next[0] = bi0; - to_next += 1; - n_left_to_next -= 1; VLIB_BUFFER_TRACE_TRAJECTORY_INIT (b0); if (PREDICT_FALSE (n_trace > 0)) |