From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-we0-f175.google.com (mail-we0-f175.google.com [74.125.82.175]) by dpdk.org (Postfix) with ESMTP id 4342EB3BD for ; Thu, 18 Sep 2014 19:08:24 +0200 (CEST) Received: by mail-we0-f175.google.com with SMTP id w61so1268525wes.20 for ; Thu, 18 Sep 2014 10:14:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding:content-type; bh=SBDNefg+MDXcDa9HHkXGHv1Dyq9KBPyVD64Ypa8SK50=; b=XNaB1FZF8Y1hi1OMUvqPRkZYJDjaZJYlgfbjItw2Bg1UX3xCHzWHVuF8Hov0PlVAdi IHGclKapXrxjIwIYbTLk1nbEortHN7oL4+2NyLs0wlXcvlKb+s2zu6v1LVieIpeS9PNQ AOGyEclJzSBBbfCuST31+rQrLpYiXq2C/MI8vQYvnFbYMrkql/JFRcJXioWF10Myctgw Lbqnt8/RBhvZq1/gV2/PAiWEdCav2BMJi7ep62G7ePaIfIaY5W3/Jfl3CXMU31AHo7P4 c1btmXOO7W3pJ64VEduB+AiMteaTZvdi+0kORnsw7X9KYMM3MvJHqLh/FzBHAtX8TAe+ 39/A== X-Gm-Message-State: ALoCoQlmP1E3WfEtFxNCkgHrBiiFJArF0XzZCW7UidrvabuaCMWzRTHkSsCMBr14v/REXWhW5Qme X-Received: by 10.194.77.111 with SMTP id r15mr6542732wjw.27.1411060450546; Thu, 18 Sep 2014 10:14:10 -0700 (PDT) Received: from xps13.localnet (14.21.90.92.rev.sfr.net. [92.90.21.14]) by mx.google.com with ESMTPSA id o3sm3684221wiy.18.2014.09.18.10.14.08 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 18 Sep 2014 10:14:09 -0700 (PDT) From: Thomas Monjalon To: "Richardson, Bruce" Date: Thu, 18 Sep 2014 19:13:52 +0200 Message-ID: <3289751.t83Qqk3rkH@xps13> Organization: 6WIND User-Agent: KMail/4.13.3 (Linux/3.15.8-1-ARCH; KDE/4.13.3; x86_64; ; ) In-Reply-To: <59AF69C657FD0841A61C55336867B5B0343F355F@IRSMSX103.ger.corp.intel.com> References: <1410948102-12740-1-git-send-email-bruce.richardson@intel.com> <20140917152945.GF4213@localhost.localdomain> <59AF69C657FD0841A61C55336867B5B0343F355F@IRSMSX103.ger.corp.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH 3/5] testpmd: Change rxfreet default to 32 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Sep 2014 17:08:24 -0000 2014-09-18 15:53, Richardson, Bruce: > > > --- a/app/test-pmd/testpmd.c > > > +++ b/app/test-pmd/testpmd.c > > > @@ -225,7 +225,7 @@ struct rte_eth_thresh tx_thresh = { > > > /* > > > * Configurable value of RX free threshold. > > > */ > > > -uint16_t rx_free_thresh = 0; /* Immediately free RX descriptors by default. */ > > > +uint16_t rx_free_thresh = 32; /* Refill RX descriptors once every 32 packets > > */ > > > > > > > Why 32? Was that an experimentally determined value? > > Does it hold true for all PMD's? > > This is primarily for the ixgbe PMD, which is right now the most > highly tuned driver, but it works fine for all other ones too, > as far as I'm aware. Yes, you are changing this value for all PMDs but you're targetting only one. These thresholds are dependent of the PMD implementation. There's something wrong here. > Basically, this is the minimum setting needed to enable either the > bulk alloc or vector RX routines inside the ixgbe driver, so it's > best made the default for that reason. Please see > "check_rx_burst_bulk_alloc_preconditions()" in ixgbe_rxtx.c, and > RX function assignment logic in "ixgbe_dev_rx_queue_setup()" in > the same file. Since this parameter is so important, it could be a default value somewhere. I think we should split generic tuning parameters and tuning parameters related to driver implementation or specific hardware. Then we should provide some good default values for each of them. At last, if needed, applications should be able to easily tune the pmd-specific parameters. Thoughts? -- Thomas