From patchwork Mon May 23 09:59:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pavan Nikhilesh Bhagavatula X-Patchwork-Id: 111605 X-Patchwork-Delegate: jerinj@marvell.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DC647A04FD; Mon, 23 May 2022 12:00:11 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BF89C40141; Mon, 23 May 2022 12:00:11 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id 6C7F740041 for ; Mon, 23 May 2022 12:00:10 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 24MNV4oc027049 for ; Mon, 23 May 2022 03:00:09 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=i4Rck+SS8i38x22oKZOGJgblMEqYzJbJRIFUrf2STTg=; b=P6r3M2lmz2Kk5t9aLLOCsUWQP/Ac9UH2yjfGnIWUduHVzo3fW+sGCTX2je4CMIvcNvqR 9SwxPs320U3iABfjt+hElASvgK5hB+YiH9wjh1FLKOPkLb56aYKeC2CNpPUrPGxscHC5 QBLJywmtf9NNzDMcNecOtE8PtvZIBvrnxnivoiNZHsxbl3MJpclwvpxi6fnDgLrPcc2n SyoXyYPX7J8D5ppSMdYNUrIjJCcCULp3YU5RLne1DIq9EW4By9FamAdwsDFylaADHghb qgY7tE2W5WgakBJ+Je0lxb0el0C+GhZKzfnq5SmZv43pk4d8jvtVONq5wkPwrRCp6X8v oQ== Received: from dc5-exch02.marvell.com ([199.233.59.182]) by mx0a-0016f401.pphosted.com (PPS) with ESMTPS id 3g6wepdjjp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT) for ; Mon, 23 May 2022 03:00:09 -0700 Received: from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Mon, 23 May 2022 03:00:07 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Mon, 23 May 2022 03:00:07 -0700 Received: from MININT-80QBFE8.corp.innovium.com (unknown [10.193.70.72]) by maili.marvell.com (Postfix) with ESMTP id 652253F70B4; Mon, 23 May 2022 03:00:02 -0700 (PDT) From: To: CC: , Pavan Nikhilesh Subject: [PATCH 1/2] app/eventdev: use mempool cache for vector pool Date: Mon, 23 May 2022 15:29:53 +0530 Message-ID: <20220523095954.3181-1-pbhagavatula@marvell.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Proofpoint-GUID: yiasrCqfOL5Y6vWmLBhWotO5lwmA4Zm0 X-Proofpoint-ORIG-GUID: yiasrCqfOL5Y6vWmLBhWotO5lwmA4Zm0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.874,Hydra:6.0.486,FMLib:17.11.64.514 definitions=2022-05-23_03,2022-05-23_01,2022-02-23_01 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Pavan Nikhilesh Use mempool cache for vector mempool as vectors are freed by the Tx routine, also increase the minimum pool size to 512 to avoid resource contention on Rx. Signed-off-by: Pavan Nikhilesh Acked-by: Jerin Jacob --- app/test-eventdev/test_pipeline_common.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/test-eventdev/test_pipeline_common.c b/app/test-eventdev/test_pipeline_common.c index c66656cd39..856a2f1a52 100644 --- a/app/test-eventdev/test_pipeline_common.c +++ b/app/test-eventdev/test_pipeline_common.c @@ -338,9 +338,10 @@ pipeline_event_rx_adapter_setup(struct evt_options *opt, uint8_t stride, if (opt->ena_vector) { unsigned int nb_elem = (opt->pool_sz / opt->vector_size) << 1; - nb_elem = nb_elem ? nb_elem : 1; + nb_elem = RTE_MAX(512U, nb_elem); + nb_elem += evt_nr_active_lcores(opt->wlcores) * 32; vector_pool = rte_event_vector_pool_create( - "vector_pool", nb_elem, 0, opt->vector_size, + "vector_pool", nb_elem, 32, opt->vector_size, opt->socket_id); if (vector_pool == NULL) { evt_err("failed to create event vector pool");