vlib: convert frame_index into real pointers 63/20663/4
authorAndreas Schultz <andreas.schultz@travelping.com>
Mon, 15 Jul 2019 13:40:56 +0000 (15:40 +0200)
committerDave Barach <openvpp@barachs.net>
Thu, 18 Jul 2019 15:07:26 +0000 (15:07 +0000)
commit58b2eb1af562c292feb6d3cdce4656746e61da75
treeba2d239dd4a2d4673ef1352143d1133a9f88ccd4
parenta0cb32cb9fba93ec4b91e7d227c07d1b2099091b
vlib: convert frame_index into real pointers

The fast path almost always has to deal with the real
pointers. Deriving the frame pointer from a frame_index requires a
load of the 32bit frame_index from memory, another 64bit load of the
heap base pointer and some calculations.

Lets store the full pointer instead and do a single 64bit load only.

This helps avoiding problems when the heap is grown and frames are
allocated below vm->heap_aligned_base.

Type: refactor
Change-Id: Ifa6e6e984aafe1e2755bff80f0a4dfcddee3623c
Signed-off-by: Andreas Schultz <andreas.schultz@travelping.com>
Signed-off-by: Dave Barach <dave@barachs.net>
src/plugins/avf/input.c
src/plugins/dpdk/device/node.c
src/plugins/memif/node.c
src/plugins/rdma/input.c
src/vlib/main.c
src/vlib/node.h
src/vlib/node_funcs.h
src/vnet/devices/virtio/vhost_user_input.c
src/vnet/pg/input.c
src/vnet/unix/gdb_funcs.c