summaryrefslogtreecommitdiffstats
path: root/src/vlib
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2018-11-18 23:48:43 +0100
committerDamjan Marion <damarion@cisco.com>2018-11-18 23:48:43 +0100
commitd30bf015ad3f7fbf206f143ed5d47a9af25148e8 (patch)
treeb9daeff94c260bd2b0df2b1b68f8bc74ce38c4ff /src/vlib
parent384a336849e031883425532029458d0f89a08c09 (diff)
add vlib_prefetch_buffer_data(...) macro
Change-Id: Iba750a41262cc028ad0363fff78cc219e4a33538 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vlib')
-rw-r--r--src/vlib/buffer.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/vlib/buffer.h b/src/vlib/buffer.h
index 99f40e840a5..493d111041e 100644
--- a/src/vlib/buffer.h
+++ b/src/vlib/buffer.h
@@ -185,6 +185,8 @@ typedef struct
*/
#define vlib_prefetch_buffer_header(b,type) CLIB_PREFETCH (b, 64, type)
+#define vlib_prefetch_buffer_data(b,type) \
+ CLIB_PREFETCH (vlib_buffer_get_current(b), CLIB_CACHE_LINE_BYTES, type)
always_inline void
vlib_buffer_struct_is_sane (vlib_buffer_t * b)