[dpdk-dev] [PATCH] mbuf: replace c memcpy code semantics with optimized rte_memcpy

Jerin Jacob jerin.jacob at caviumnetworks.com
Fri May 27 13:42:08 CEST 2016


On Fri, May 27, 2016 at 11:24:57AM +0100, Hunt, David wrote:
> 
> 
> On 5/24/2016 4:17 PM, Jerin Jacob wrote:
> > On Tue, May 24, 2016 at 04:59:47PM +0200, Olivier Matz wrote:
> > 
> > > Are you seeing some performance improvement by using rte_memcpy()?
> > Yes, In some case, In default case, It was replaced with memcpy by the
> > compiler itself(gcc 5.3). But when I tried external mempool manager patch and
> > then performance dropped almost 800Kpps. Debugging further it turns out that
> > external mempool managers unrelated change was knocking out the memcpy.
> > explicit rte_memcpy brought back 500Kpps. Remaing 300Kpps drop is still
> > unknown(In my test setup, packets are in the local cache, so it must be
> > something do with __mempool_put_bulk text alignment change or similar.
> > 
> > Anyone else observed performance drop with external poolmanager?
> > 
> > Jerin
> 
> Jerin,
>     I'm seeing a 300kpps drop in throughput when I apply this on top of the
> external
> mempool manager patch. If you're seeing an increase if you apply this patch
> first, then
> a drop when applying the mempool manager, the two patches must be
> conflicting in
> some way. We probably need to investigate further.

In general, My concern is that most probably this patch also will get dropped
on floor due to conflit in different architecture and some architecture/platform
need to maintain this out out tree.

Unlike other projects, DPDK modules are hand optimized due do that
some change are depended register allocations and compiler version and
text alignment etc.

IMHO, I think we should have means to abstract this _logical_ changes
under conditional compilation flags and any arch/platform can choose
to select what it suites better for that arch/platform.

We may NOT need to have frequent patches to select the specific
configuration, but logical patches under compilation flags can be accepted and
each arch/platform can choose specific set configuration when we make
the final release candidate for the release.

Any thoughts?

Jerin



More information about the dev mailing list