From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 809B4A04FD; Tue, 14 Jan 2020 07:27:33 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 1B7F51C2AB; Tue, 14 Jan 2020 07:27:33 +0100 (CET) Received: from mail-io1-f66.google.com (mail-io1-f66.google.com [209.85.166.66]) by dpdk.org (Postfix) with ESMTP id A4EE11C2AA for ; Tue, 14 Jan 2020 07:27:31 +0100 (CET) Received: by mail-io1-f66.google.com with SMTP id n11so12578617iom.9 for ; Mon, 13 Jan 2020 22:27:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=juH36WQoTd506voYFQqKfxBJOVmI24L0X704nxfLc6Q=; b=hWWPpbVKnhq8os7ch82hsPdQo+DzeZgJeMGZkeye5BUt6prUtJYs3c4wv3Gd5FiUui qME42Z2o8spoZ0tsFBUnJfNnEFsS7xDewAgayOog20EtSznP7xcDOUxOjhu4y/05gaY6 /n+Mb5mfVW4exTgEivAPL9c4UYxdK5NpKA1KMdfnCi/WCTiaB9YiQ7ustj0hTG0ZRBQ9 MK95C4GlFfF6RAMyb6v9IjtcP+weakPUBxXkwjxRfvSfkwrHVnPD5HxmDjxUfaG/g4mA jKAZS2qIZkT9ifT+yGl+oVqEgiWh06zZM41c09o+6TeU2YNBBuNuk5F3ozWUkd74fhww K+hA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=juH36WQoTd506voYFQqKfxBJOVmI24L0X704nxfLc6Q=; b=FayaZqvSZN1fAVK8LswD48/azj9hitTO92+m83V2BlpD/uoDvMGMTl5Zt6SZwTOUvQ wQ/eOwuT5lRokQ62Z1MKarqKz5l8q0YoinvRQZZ6yMXAmNyPM8b5itFTdQ0BXicI2SMX mR2GZfzN9w68ocoXxGtKTsOB3xE4b8EL7dtisnwvB274hSpaR53kk4aZ8ATI5wtjsMCb Py7kjyvBUR+4cFY+pd9cz6mOdWTRxGnW1i/N/Wgw0Ee+xZgxrecYJnYXzj44DCSSkJKt TgzrpNZ2ETsSz0kZ2QL8ET+gzh60mxOqP8up2+XHEDef7t+60fX2CCsuaXQAvpqA5fOQ qJCg== X-Gm-Message-State: APjAAAV6J3gOtsCg/pHgosyU4Ze0b5rRY2upQU1TcrFeaboIx1md02Cx rVFda8d5WIgEqkbg5GcQcgiYeOM/qfrapxIm0FU= X-Google-Smtp-Source: APXvYqyqkVeqz/McmEo1gSJyswA1X98TMaN4KI+K6iwCWHiiuR1NKv0WerwV7XBvkHRd3Xpsc3DCvVKkcvxiCbQgm9Y= X-Received: by 2002:a6b:c742:: with SMTP id x63mr15931664iof.162.1578983250901; Mon, 13 Jan 2020 22:27:30 -0800 (PST) MIME-Version: 1.0 References: <20200111135440.6720-1-pbhagavatula@marvell.com> <20200111135742.7782-1-pbhagavatula@marvell.com> In-Reply-To: <20200111135742.7782-1-pbhagavatula@marvell.com> From: Jerin Jacob Date: Tue, 14 Jan 2020 11:57:14 +0530 Message-ID: To: Pavan Nikhilesh , Ferruh Yigit Cc: Jerin Jacob , Nithin Dabilpuram , Kiran Kumar K , dpdk-dev Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH v2] net/octeontx2: perf improvement to Tx vector func X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Sat, Jan 11, 2020 at 7:27 PM wrote: > > From: Pavan Nikhilesh > > Use scalar loads instead of vector loads for fields > that don't need any vector operations. > > Signed-off-by: Pavan Nikhilesh Acked-by: Jerin Jacob Applied to dpdk-next-net-mrvl/master. Thanks > --- > drivers/net/octeontx2/otx2_tx.c | 15 +++++---------- > 1 file changed, 5 insertions(+), 10 deletions(-) > > diff --git a/drivers/net/octeontx2/otx2_tx.c b/drivers/net/octeontx2/otx2_tx.c > index fa533000e..9f5926560 100644 > --- a/drivers/net/octeontx2/otx2_tx.c > +++ b/drivers/net/octeontx2/otx2_tx.c > @@ -112,7 +112,6 @@ nix_xmit_pkts_vector(void *tx_queue, struct rte_mbuf **tx_pkts, > uint64x2_t ltypes01, ltypes23; > uint64x2_t xtmp128, ytmp128; > uint64x2_t xmask01, xmask23; > - uint64x2_t mbuf01, mbuf23; > uint64x2_t cmd00, cmd01; > uint64x2_t cmd10, cmd11; > uint64x2_t cmd20, cmd21; > @@ -137,9 +136,6 @@ nix_xmit_pkts_vector(void *tx_queue, struct rte_mbuf **tx_pkts, > sgdesc23_w0 = sgdesc01_w0; > > for (i = 0; i < pkts; i += NIX_DESCS_PER_LOOP) { > - mbuf01 = vld1q_u64((uint64_t *)tx_pkts); > - mbuf23 = vld1q_u64((uint64_t *)(tx_pkts + 2)); > - > /* Clear lower 32bit of SEND_HDR_W0 and SEND_SG_W0 */ > senddesc01_w0 = vbicq_u64(senddesc01_w0, > vdupq_n_u64(0xFFFFFFFF)); > @@ -149,13 +145,11 @@ nix_xmit_pkts_vector(void *tx_queue, struct rte_mbuf **tx_pkts, > senddesc23_w0 = senddesc01_w0; > sgdesc23_w0 = sgdesc01_w0; > > - tx_pkts = tx_pkts + NIX_DESCS_PER_LOOP; > - > /* Move mbufs to iova */ > - mbuf0 = (uint64_t *)vgetq_lane_u64(mbuf01, 0); > - mbuf1 = (uint64_t *)vgetq_lane_u64(mbuf01, 1); > - mbuf2 = (uint64_t *)vgetq_lane_u64(mbuf23, 0); > - mbuf3 = (uint64_t *)vgetq_lane_u64(mbuf23, 1); > + mbuf0 = (uint64_t *)tx_pkts[0]; > + mbuf1 = (uint64_t *)tx_pkts[1]; > + mbuf2 = (uint64_t *)tx_pkts[2]; > + mbuf3 = (uint64_t *)tx_pkts[3]; > > mbuf0 = (uint64_t *)((uintptr_t)mbuf0 + > offsetof(struct rte_mbuf, buf_iova)); > @@ -927,6 +921,7 @@ nix_xmit_pkts_vector(void *tx_queue, struct rte_mbuf **tx_pkts, > lmt_status = otx2_lmt_submit(io_addr); > > } while (lmt_status == 0); > + tx_pkts = tx_pkts + NIX_DESCS_PER_LOOP; > } > > return pkts; > -- > 2.17.1 >