From patchwork Fri Dec 20 04:45:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Honnappa Nagarahalli X-Patchwork-Id: 182215 Delivered-To: patch@linaro.org Received: by 2002:a92:1f98:0:0:0:0:0 with SMTP id f24csp59152ilf; Thu, 19 Dec 2019 20:48:22 -0800 (PST) X-Google-Smtp-Source: APXvYqyh6vu1NzDQZuyImXM4yioC+k6Xjy+SgcmV8ELPEjgbKxxrM3YvT3flhJCdw5lHf97iUenZ X-Received: by 2002:adf:e591:: with SMTP id l17mr11957646wrm.139.1576817302230; Thu, 19 Dec 2019 20:48:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576817302; cv=none; d=google.com; s=arc-20160816; b=ATftnPw3aa3ipXW5uALSac/f0/yMgCswhnOrilOUX4JHN+WkTrka/oqlzcbc5N4UC9 ZHo4+oypgw4AoWjJJWEuEz/FbhoXYu9+AWHQY7od1WopG+cL4iHRGZIt0n9P+si3Z3/W t15IxQX+rZp32Fd26/cwLm7rw6jHZilhqQVnRsv0EvdafFz0XxWRiimlAENRKb5ecYvW n06Efoo00hpgxC2S8KSXzXixGcn4dPQlHWZ5eCgCFfePaN+bfviRWOsPNF0qmSn93XG2 3pi17x34uootkV/rJsrwRNnaycjljTKC5vW1ADBFdyj8BnBi8GJdTeSxi6PRjQwucY6h /r8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:references:in-reply-to :message-id:date:cc:to:from; bh=2OT9t5rd8uF2UV8KXAJsekvbNV2frEX6WGaHS7zYX5I=; b=ERBAng4Ur6eUHZ8/q2CXu76bnkSm/UbmViy35Vc84tpVcf35ECZDgCKgnNVNQrG3O4 FeTuJelY6dg8mCdlKnk6fWrLnqSX4/QOCOcbS7o463W/TIXjGF5fy51Mdpcosva6Qkm9 43E67FCnNcxSGqbAQNXGsQRAcbIusUBNe7pu2i4YH7ZUREqxbCZ8CQfv4MSi806/h9dd LjfQ1+HHQ17wqmjf09CRYh2rEeiTS+PvGqvwyv8wYrrMXgfWoB3EOnzK9S2Uwix4JRJD lcnbozy+YXyuG2CVlRZfcmTpcVZ3RiUcxJ1BL8BrBh7PZ43U9viI9gYxTdmoIITgrDTA 3+Kw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org Return-Path: Received: from dpdk.org (dpdk.org. [92.243.14.124]) by mx.google.com with ESMTP id k17si8891416wrg.369.2019.12.19.20.48.21; Thu, 19 Dec 2019 20:48:22 -0800 (PST) Received-SPF: pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) client-ip=92.243.14.124; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 48CB21BFD1; Fri, 20 Dec 2019 05:46:28 +0100 (CET) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by dpdk.org (Postfix) with ESMTP id 107AA1BF73 for ; Fri, 20 Dec 2019 05:46:00 +0100 (CET) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8DEA9142F; Thu, 19 Dec 2019 20:45:57 -0800 (PST) Received: from qc2400f-1.austin.arm.com (qc2400f-1.austin.arm.com [10.118.14.48]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 833093F718; Thu, 19 Dec 2019 20:45:57 -0800 (PST) From: Honnappa Nagarahalli To: olivier.matz@6wind.com, sthemmin@microsoft.com, jerinj@marvell.com, bruce.richardson@intel.com, david.marchand@redhat.com, pbhagavatula@marvell.com, konstantin.ananyev@intel.com, honnappa.nagarahalli@arm.com Cc: dev@dpdk.org, dharmik.thakkar@arm.com, ruifeng.wang@arm.com, gavin.hu@arm.com, nd@arm.com Date: Thu, 19 Dec 2019 22:45:18 -0600 Message-Id: <20191220044524.32910-12-honnappa.nagarahalli@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191220044524.32910-1-honnappa.nagarahalli@arm.com> References: <20190906190510.11146-1-honnappa.nagarahalli@arm.com> <20191220044524.32910-1-honnappa.nagarahalli@arm.com> Subject: [dpdk-dev] [PATCH v7 11/17] test/ring: modify burst enq/deq perf test cases 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" Add test cases to test legacy and rte_ring_xxx_elem APIs for burst enqueue/dequeue test cases. Signed-off-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu --- app/test/test_ring_perf.c | 78 ++++++++++++++++++++------------------- 1 file changed, 40 insertions(+), 38 deletions(-) -- 2.17.1 diff --git a/app/test/test_ring_perf.c b/app/test/test_ring_perf.c index 5829718c1..508c688dc 100644 --- a/app/test/test_ring_perf.c +++ b/app/test/test_ring_perf.c @@ -397,47 +397,40 @@ test_single_enqueue_dequeue(struct rte_ring *r, const int esize, } /* - * Test that does both enqueue and dequeue on a core using the burst() API calls - * instead of the bulk() calls used in other tests. Results should be the same - * as for the bulk function called on a single lcore. + * Test that does both enqueue and dequeue on a core using the burst/bulk API + * calls Results should be the same as for the bulk function called on a + * single lcore. */ -static void -test_burst_enqueue_dequeue(struct rte_ring *r) +static int +test_burst_bulk_enqueue_dequeue(struct rte_ring *r, const int esize, + const unsigned int api_type) { - const unsigned iter_shift = 23; - const unsigned iterations = 1<