From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ua0-f172.google.com (mail-ua0-f172.google.com [209.85.217.172]) by dpdk.org (Postfix) with ESMTP id C8E382BDB for ; Wed, 24 Aug 2016 00:42:31 +0200 (CEST) Received: by mail-ua0-f172.google.com with SMTP id n59so270041093uan.2 for ; Tue, 23 Aug 2016 15:42:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bigswitch-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=McwJTp385E6rXduvipFPhIWT9+idUQtb2ZRvqh3IgCk=; b=E1clvOYZM4SLK6e6DN//Mr7h4TEkvnqNl2Fu3ocbHfT148PnnBOxWWqaqCyoA/oNRu /IurX5nyqfR18PPcOGM2C1IFn+f1DHkX4B2Rmp4wRTPbITAKAp2dQjnmJLdQazoYoeJE laY+mAAiV3/JW522e0gOnuJOLNZLrcsnPVq2F5a8ZuZSmrJUoENjYBu6d1xpc8WLAl39 CBGJ6aWtD654+k3YaLJfNaJsZWYsGwkNmk3HHt84ITrnDjFNtWeIDj2uH+65f9TJgZXm 5vuZQ236W7CTiJ+SEs7rWRLWfo7lbHi2fMej7lROiAAcy4f+HZi77bWMKHXimL03n4CI drrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=McwJTp385E6rXduvipFPhIWT9+idUQtb2ZRvqh3IgCk=; b=jh2uB+WWCWdXV1L2SKKdrrgPPi2xpFevTzxN6w+rbta5tvsI7cVIMiyyyRiA9XTNOP fzIM1B/GogXmmsRyffIZOjVFoy8ShTAjakDJ42hTiNKXWE/na/N2pIwhj42MdM1XiyDi F5rEFxCxL3HkdWttGWZL90wWGJGpEsX7FMAqYZmkQeG2WAy9ec88Zajv3OfdhyB+7aeD qcJ5M532xfqtNE+JWSmQHLzn0LgUHSviYGs2hebkIZndvJnYhEArok2u8k6cz+PZfv7r SNjxRM3G9VjqWKp4ELKvkDuhTpis550PUuSv+6ZKJJPkydvXfN8CPvPQBEzLUxVfFMo3 agOw== X-Gm-Message-State: AEkoouuVSU6nhPXXTjlFSzRPEpsm67THgBd0yyGZnZMXObejusyv/y+UJTPD0QBoJJErhSuU/svMfG5E+LsUClZA X-Received: by 10.31.158.200 with SMTP id h191mr16116778vke.127.1471992151253; Tue, 23 Aug 2016 15:42:31 -0700 (PDT) MIME-Version: 1.0 Received: by 10.31.50.199 with HTTP; Tue, 23 Aug 2016 15:42:30 -0700 (PDT) In-Reply-To: <20160822141636.GC30752@yliu-dev.sh.intel.com> References: <1471291224-12755-1-git-send-email-rich.lane@bigswitch.com> <20160816023715.GL30752@yliu-dev.sh.intel.com> <20160822141636.GC30752@yliu-dev.sh.intel.com> From: Rich Lane Date: Tue, 23 Aug 2016 15:42:30 -0700 Message-ID: To: Yuanhan Liu Cc: dev@dpdk.org, Huawei Xie , "Wang, Zhihong" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH] vhost: add back support for concurrent enqueue X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Aug 2016 22:42:32 -0000 On Mon, Aug 22, 2016 at 7:16 AM, Yuanhan Liu wrote: > On Thu, Aug 18, 2016 at 11:27:06AM -0700, Rich Lane wrote: > > On Mon, Aug 15, 2016 at 7:37 PM, Yuanhan Liu < > yuanhan.liu@linux.intel.com> > > wrote: > > > > On Mon, Aug 15, 2016 at 01:00:24PM -0700, Rich Lane wrote: > > > Concurrent enqueue is an important performance optimization when > the > > number > > > of cores used for switching is different than the number of vhost > queues. > > > I've observed a 20% performance improvement compared to a strateg= y > that > > > binds queues to cores. > > > > > > The atomic cmpset is only executed when the application calls > > > rte_vhost_enqueue_burst_mp. Benchmarks show no performance impact > > > when not using concurrent enqueue. > > > > > > Mergeable RX buffers aren't supported by concurrent enqueue to > minimize > > > code complexity. > > > > I think that would break things when Mergeable rx is enabled (which > is > > actually enabled by default). > > > > > > Would it be reasonable to return -ENOTSUP in this case, and restrict > concurrent > > enqueue > > to devices where VIRTIO_NET_F_MRG_RXBUF is disabled? > > > > I could also add back concurrent enqueue support for mergeable RX, but = I > was > > hoping to avoid > > that since the mergeable codepath is already complex and wouldn't be > used in > > high performance > > deployments. > > Another note is that, you might also have noticed, Zhihong made a patch > set [0] to optimize the enqueue code path (mainly on mergeable path). It > basically does a rewrite from scatch, which removes the desc buf > reservation, > meaning it would be harder to do concurrent enqueue support based on that= . > > [0]: Aug 19 Zhihong Wang ( 68) =E2=94=9C=E2=94=80>[PATCH v3 0/5] vhos= t: optimize > enqueue > Yes, I'd noticed that these patches would conflict. Once the vhost-cuse removal and Zhihong's patches have merged I'll send a new version.