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 BA932A0C56; Thu, 12 Aug 2021 13:11:31 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 81ABD41205; Thu, 12 Aug 2021 13:11:24 +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 E998A41215 for ; Thu, 12 Aug 2021 13:11:22 +0200 (CEST) Received: by mail-pj1-f50.google.com with SMTP id bo18so8912597pjb.0 for ; Thu, 12 Aug 2021 04:11:22 -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=PJ2QAjalfb6+Qr4j/FjUiZAd+hLRVOClwsPDQlpwCKNUMyF6dS6V2PDfos7yeOz/mg VT1VidFrUPrkxJiXdhLnO49SohX5CjmoX0hilU9o0ggvtRtVwpAL7H6Z7M6fAr9P1prs Xm7EQh5xPj58jgNhRg57TbX+2v98e1N0uf6P0uraOuWTw236pCqM5xE8MMsG9uFpSWtU g3aJ7utDZXjMBowJsCxq5DxtJ0xNsNVOpcealCIQmUQ0XcPQpsQu+vgr1RhOQF+MZK+F 8cf3ZE23CxefIa1yW7sy20LO5LyVvYjMH8xTWlgcec8ki0cu1DWt5wGbAPZDLNDpDQbr 394g== 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=qudb2ANsM0CuQqKn0uj6p5/qUzhLNbgkVf5Aud4YvTznBaC40gFdjV9r+Ur/8wmiUn E/h7h/WG7HHnojXD4aV8eqiNmbxd1XLlg+0nYqJsq2kj4YBS2MJn0U8lR9qM+7gRufh2 sb1G9F4aiI/qyvMOkvcYb7NiofCcPzZ6ZmXrs4icNNsHkVhTkmzSCEWwHKcHBwJ8Lo9Q b2+WjNibfOeN9oXawpqcMMJmjSLOUuGt3Z+JNVfnHvesZIVpF00k7kuRjOuxEyXwc+s0 j85F4hee0B/v1GdwlXELU1pcWf9Ewfitxu54/rIx1cvZuNnhMz2kijYgqyxKSORP2Sm7 SYgw== X-Gm-Message-State: AOAM533wqG1jb4Ro3xGsW+H8QKy+wlnk7NVDFRuk5MPqQL7jCk+sVAo6 lnyZt0USSXADz+kAEXUmmbv2z5Mo9iOBjA== X-Google-Smtp-Source: ABdhPJxdepYheC8XBnKULGdT1CqT9hEjJDnBaNanhxZhj71GHfb1ILe+mRyj5RuaGoUZZZfADK+GNw== X-Received: by 2002:a17:902:9a8b:b029:12d:7179:2f6d with SMTP id w11-20020a1709029a8bb029012d71792f6dmr3243684plp.54.1628766681906; Thu, 12 Aug 2021 04:11:21 -0700 (PDT) Received: from C02D70YZMD6R.bytedance.net ([139.177.225.243]) by smtp.gmail.com with ESMTPSA id l126sm3291830pgl.14.2021.08.12.04.11.18 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 12 Aug 2021 04:11:21 -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 19:11:04 +0800 Message-Id: <20210812111105.54307-4-wangzhihong.wzh@bytedance.com> X-Mailer: git-send-email 2.24.3 (Apple Git-128) In-Reply-To: <20210812111105.54307-1-wangzhihong.wzh@bytedance.com> References: <20210809062548.30187-1-wangzhihong.wzh@bytedance.com> <20210812111105.54307-1-wangzhihong.wzh@bytedance.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v3 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