summaryrefslogtreecommitdiffstats
path: root/hicn-plugin/src/faces/ip/iface_ip_node.c
diff options
context:
space:
mode:
authorAlberto Compagno <acompagn+fdio@cisco.com>2019-01-19 17:28:57 +0100
committerAlberto Compagno <acompagn+fdio@cisco.com>2019-01-19 17:35:54 +0100
commitc7f942175b8c25c77ddc21561b52e3e6b5620b80 (patch)
treed9cecc4574ae9ed2f4a9e041010c8794e6001363 /hicn-plugin/src/faces/ip/iface_ip_node.c
parentd13d37534d9449dd54277af664310d5f957dc44a (diff)
Improved performance on data-fwd node:
- Removed full pit entry initialization in favor of a lighter initialization on few fields - Squeezed pit entry size in order to store only the number of incomplete faces (as set in HICN_PARAM_PIT_ENTRY_PHOPS_MAX). The bitmap size is now determined by HICN_PARAM_FACES_MAX and optimized to do a fast lookup Replaced the field is_appface with the field flags in the hicn_buffer_t: - is_appface is now a flag with value 0x01 (HICN_BUFFER_FLAGS_FACE_IS_APP) - Added flag HICN_BUFFER_FLAGS_PKT_LESS_TWO_CL (0x02) to handle the copy of pkt with length < than 2*CACHE_LINES (in this case cloning is prevented by the cloning function in vpp). Such flag is initialized by the incoming face of the pkt. Change-Id: Ia956fd5719a28ee29f7fa2fd23d283964743efd8 Signed-off-by: Alberto Compagno <acompagn+fdio@cisco.com>
Diffstat (limited to 'hicn-plugin/src/faces/ip/iface_ip_node.c')
-rwxr-xr-xhicn-plugin/src/faces/ip/iface_ip_node.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/hicn-plugin/src/faces/ip/iface_ip_node.c b/hicn-plugin/src/faces/ip/iface_ip_node.c
index 8df0467f0..9ca00d7bf 100755
--- a/hicn-plugin/src/faces/ip/iface_ip_node.c
+++ b/hicn-plugin/src/faces/ip/iface_ip_node.c
@@ -143,7 +143,7 @@ typedef enum
{ \
vlib_buffer_t *b1; \
b1 = vlib_get_buffer (vm, from[1]); \
- CLIB_PREFETCH (b1, 2*CLIB_CACHE_LINE_BYTES, STORE); \
+ CLIB_PREFETCH (b1, 2*CLIB_CACHE_LINE_BYTES, STORE); \
CLIB_PREFETCH (b1->data, CLIB_CACHE_LINE_BYTES , LOAD); \
} \
/* Dequeue a packet buffer */ \
@@ -171,7 +171,7 @@ typedef enum
\
DPO_ADD_LOCK_IP##ipv \
(&(hicnb0->face_dpo_id), \
- &hicnb0->is_appface, \
+ &hicnb0->flags, \
local_address, \
&(ip_hdr->src_address), \
vnet_buffer(b0)->sw_if_index[VLIB_RX], \
@@ -248,7 +248,7 @@ typedef enum
\
DPO_ADD_LOCK_IP##ipv \
(&(hicnb0->face_dpo_id), \
- &hicnb0->is_appface, \
+ &hicnb0->flags, \
local_address0, \
&(ip_hdr0->src_address), \
vnet_buffer(b0)->sw_if_index[VLIB_RX], \
@@ -256,7 +256,7 @@ typedef enum
\
DPO_ADD_LOCK_IP##ipv \
(&(hicnb1->face_dpo_id), \
- &hicnb1->is_appface, \
+ &hicnb1->flags, \
local_address1, \
&(ip_hdr1->src_address), \
vnet_buffer(b1)->sw_if_index[VLIB_RX], \