16994abee2
When any layout is used, the header is stored in the head room of mbuf. mbuf is allocated and filled by user, means there is no gurateen the header is all zero for non TSO case. Therefore, we have to do the reset by ourself: memest(hdr, 0, head_size); The memset has two impacts on performance: - memset could not be inlined, which is a bit costly. - more importantly, it touches the mbuf, which could introduce severe cache issues as described by former patch. Similiary, we could do the same trick: reset just when necessary, when the corresponding field is already 0, which is likely true for a simple l2 forward case. It could boost the performance up to 20+% in micro benchmarking. Cc: stable@dpdk.org Cc: Maxime Coquelin <maxime.coquelin@redhat.com> Cc: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Yuanhan Liu <yuanhan.liu@linux.intel.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com> |
||
---|---|---|
.. | ||
af_packet | ||
bnx2x | ||
bnxt | ||
bonding | ||
cxgbe | ||
e1000 | ||
ena | ||
enic | ||
fm10k | ||
i40e | ||
ixgbe | ||
mlx4 | ||
mlx5 | ||
mpipe | ||
nfp | ||
null | ||
pcap | ||
qede | ||
ring | ||
sfc | ||
szedata2 | ||
tap | ||
thunderx | ||
vhost | ||
virtio | ||
vmxnet3 | ||
xenvirt | ||
Makefile |