From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2BC25A0C4E; Thu, 12 Aug 2021 15:19:33 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3360541223; Thu, 12 Aug 2021 15:19:21 +0200 (CEST) Received: from mail-pj1-f50.google.com (mail-pj1-f50.google.com [209.85.216.50]) by mails.dpdk.org (Postfix) with ESMTP id AA5B040042 for ; Thu, 12 Aug 2021 15:19:19 +0200 (CEST) Received: by mail-pj1-f50.google.com with SMTP id cp15-20020a17090afb8fb029017891959dcbso15131765pjb.2 for ; Thu, 12 Aug 2021 06:19:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=qVq3MNIRBAU+5MFzYuHD6SlzXnuY96/Dmui4y7Yq828=; b=cqqYTrg9QrtAXMn59vmauSAQ8BKOZ1/SpF26anOpAf/T45LFzXYjpDEEJFtJ0HQWmd U9nTnj3QeNHQA/q5rOwiSepnfWsySJzf657vbOAnYudSq+J+z6x8nk8PhFC8/rRG1jIt IbZ3zAtNEDmaB1xE45g4xTLfliX7YYNTiOakmnJ/uFYY0UJSZU9mr/mJFs+ckcjFjZV7 nBQyaawKtc0qFwD36mO0nVFXBrW9sVBfliCZt+bVRkXLRZbgXMfHnOhBci/6wReNJiZI Agei85QZs6wZKt8m9g+DQ+18NVrN0Iaxn9OzTgJb0jraHkJLKlTlUgBMIhsDSL+zLhkL pz8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=qVq3MNIRBAU+5MFzYuHD6SlzXnuY96/Dmui4y7Yq828=; b=t2ixS9N0bP1/I3saMBVlZ0S5HFPqL+xh8uEESNvCYg++UG0WeSNzh8uNzQNzEGFGLy rq2p6YUvjTkpxj3umVUOG+M0auecVmOsOturhFxLmCISOBXRN6ekKaYIV9t9pdtbT8ix A8HJCAdb4k9/o+YVUULoNYhvMngkFI0toNRxWjZFmXeG8gZPKVYH2P/UgEixYcKzO+Je iob8i9/N8VHwzIQetAuxRxHeCuab9R/cCmmiwx00S/kOzaEiwe940w4M9/hkLmf2Frcm Ui6ah9iFs6tPvfmzSW19hwoDqfEe/ZUlxoEkjKqCM77nohwir0yNVZQtgb6EBtnmjjQ2 8hEQ== X-Gm-Message-State: AOAM531RcbprPYJZFEgz0kOqQkV7Y4ljjuR5mPCFMtdeYepHe2oZ3YRI 3Q9MJQxl6CbBOsM0OhkmowLxPsWCi5cEsQ== X-Google-Smtp-Source: ABdhPJwvZGPDBNfebkci3QSke1rRcwG3xENyiX8ZVT5DCDxloQszNrcdcGGsaajd4/uUq9vADNn0Og== X-Received: by 2002:a17:902:7fc6:b029:12d:1a3c:a981 with SMTP id t6-20020a1709027fc6b029012d1a3ca981mr3519681plb.46.1628774358519; Thu, 12 Aug 2021 06:19:18 -0700 (PDT) Received: from C02D70YZMD6R.bytedance.net ([139.177.225.227]) by smtp.gmail.com with ESMTPSA id x24sm10273416pjk.43.2021.08.12.06.19.15 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 12 Aug 2021 06:19:17 -0700 (PDT) From: Zhihong Wang To: dev@dpdk.org, ferruh.yigit@intel.com, xiaoyun.li@intel.com, aman.deep.singh@intel.com, irusskikh@marvell.com, cchemparathy@tilera.com Cc: Zhihong Wang Date: Thu, 12 Aug 2021 21:19:00 +0800 Message-Id: <20210812131901.25665-4-wangzhihong.wzh@bytedance.com> X-Mailer: git-send-email 2.24.3 (Apple Git-128) In-Reply-To: <20210812131901.25665-1-wangzhihong.wzh@bytedance.com> References: <20210809062548.30187-1-wangzhihong.wzh@bytedance.com> <20210812131901.25665-1-wangzhihong.wzh@bytedance.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v4 3/4] app/testpmd: record rx_burst and fwd_dropped in flowgen 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 Sender: "dev" Call inc_rx_burst_stats for rx operation, and record fwd_dropped. Signed-off-by: Zhihong Wang --- app/test-pmd/flowgen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/test-pmd/flowgen.c b/app/test-pmd/flowgen.c index 96d0cc79df..229794ee9c 100644 --- a/app/test-pmd/flowgen.c +++ b/app/test-pmd/flowgen.c @@ -87,6 +87,7 @@ pkt_burst_flow_gen(struct fwd_stream *fs) /* Receive a burst of packets and discard them. */ nb_rx = rte_eth_rx_burst(fs->rx_port, fs->rx_queue, pkts_burst, nb_pkt_per_burst); + inc_rx_burst_stats(fs, nb_rx); fs->rx_packets += nb_rx; for (i = 0; i < nb_rx; i++) @@ -186,6 +187,7 @@ pkt_burst_flow_gen(struct fwd_stream *fs) while (next_flow < 0) next_flow += cfg_n_flows; + fs->fwd_dropped += nb_pkt - nb_tx; do { rte_pktmbuf_free(pkts_burst[nb_tx]); } while (++nb_tx < nb_pkt); -- 2.11.0