diff options
author | Dave Barach <dave@barachs.net> | 2018-11-13 16:34:13 -0500 |
---|---|---|
committer | Florin Coras <florin.coras@gmail.com> | 2018-11-14 15:54:01 +0000 |
commit | 178cf493d009995b28fdf220f04c98860ff79a9b (patch) | |
tree | 097c1be82b8f6fa9bc04b9b1e193158e2e4997eb /src/plugins/ioam/ip6/ioam_cache_node.c | |
parent | 6917b94f2146aa51195a6a2a1ccd8416a1d74bf3 (diff) |
Remove c-11 memcpy checks from perf-critical code
Change-Id: Id4f37f5d4a03160572954a416efa1ef9b3d79ad1
Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/plugins/ioam/ip6/ioam_cache_node.c')
-rw-r--r-- | src/plugins/ioam/ip6/ioam_cache_node.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/plugins/ioam/ip6/ioam_cache_node.c b/src/plugins/ioam/ip6/ioam_cache_node.c index dd27e127a09..59bc1a64811 100644 --- a/src/plugins/ioam/ip6/ioam_cache_node.c +++ b/src/plugins/ioam/ip6/ioam_cache_node.c @@ -344,17 +344,17 @@ ip6_add_from_cache_hbh_node_fn (vlib_main_t * vm, hbh0 = (ip6_hop_by_hop_header_t *) (ip0 + 1); srh0 = (ip6_sr_header_t *) ((u8 *) hbh0 + rewrite_len); /* $$$ tune, rewrite_len is a multiple of 8 */ - clib_memcpy (hbh0, rewrite, rewrite_len); - clib_memcpy (srh0, cm->sr_rewrite_template, sr_rewrite_len); + clib_memcpy_fast (hbh0, rewrite, rewrite_len); + clib_memcpy_fast (srh0, cm->sr_rewrite_template, sr_rewrite_len); /* Copy dst address into the DA slot in the segment list */ - clib_memcpy (srh0->segments, ip0->dst_address.as_u64, - sizeof (ip6_address_t)); + clib_memcpy_fast (srh0->segments, ip0->dst_address.as_u64, + sizeof (ip6_address_t)); /* Rewrite the ip6 dst address with the first hop */ - clib_memcpy (ip0->dst_address.as_u64, entry->next_hop.as_u64, - sizeof (ip6_address_t)); - clib_memcpy (&srh0->segments[1], - (u8 *) hbh0 + entry->my_address_offset, - sizeof (ip6_address_t)); + clib_memcpy_fast (ip0->dst_address.as_u64, entry->next_hop.as_u64, + sizeof (ip6_address_t)); + clib_memcpy_fast (&srh0->segments[1], + (u8 *) hbh0 + entry->my_address_offset, + sizeof (ip6_address_t)); ioam_cache_entry_free (entry); /* Patch the protocol chain, insert the h-b-h (type 0) header */ |