From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Dumazet Subject: Re: [PATCH net-next v2] net: Add sysctl to toggle early demux for tcp and udp Date: Sun, 19 Mar 2017 12:18:39 -0700 Message-ID: <1489951119.16816.3.camel@edumazet-glaptop3.roam.corp.google.com> References: <1489116660-4244-1-git-send-email-subashab@codeaurora.org> <674d67f5d76f761f3e872dff274a8bda@codeaurora.org> <1489191742.28631.35.camel@edumazet-glaptop3.roam.corp.google.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: Tom Herbert , Linux Kernel Network Developers , Stephen Hemminger , netdev-owner@vger.kernel.org To: Subash Abhinov Kasiviswanathan Return-path: Received: from mail-pg0-f68.google.com ([74.125.83.68]:35641 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751643AbdCSTSn (ORCPT ); Sun, 19 Mar 2017 15:18:43 -0400 In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: On Sat, 2017-03-18 at 20:07 -0600, Subash Abhinov Kasiviswanathan wrote: > > Less than 1% performance improvement in a benchmark doesn't justify > > the complexity of the patch. Eric's hypothesis was that an unconnected > > UDP socket may show issues because of cache misses in look-ups due to > > so many different sources. This should be fairly easy to benchmark by > > randomly setting source address in your test (IP any and routing my > > need to be set appropriately). > > > > With different source addresses, a larger increase is seen here > (633->654Mbps). Yes, also note the extra cache line might be not noticed if the cpu can keep in its caches the whole UDP hash table (1 MB on 64bit kernels for the portion touched in IP early demux) So the exact slowdown depends on CPU generation / cache sizes.