From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 43ABFA04D8; Mon, 21 Sep 2020 17:42:34 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 221E91C1E5; Mon, 21 Sep 2020 17:42:34 +0200 (CEST) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id 103EC1C199 for ; Mon, 21 Sep 2020 17:42:32 +0200 (CEST) IronPort-SDR: 26xYG9GuAlbOj8RH1+mfyTD6bg/2N3MjLRIHuT2i8GjYAw3teQOwxVemoeCeb809Of+lC2NZFP BJFEJoxDeJAg== X-IronPort-AV: E=McAfee;i="6000,8403,9751"; a="222002629" X-IronPort-AV: E=Sophos;i="5.77,287,1596524400"; d="scan'208";a="222002629" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Sep 2020 08:42:32 -0700 IronPort-SDR: akIrTzTbq71v4LXh3sEu6UG4xwCSiAWBtaruscsqKWMa5ommaguNPvKO3lhdjFssJEefjplOo1 +iBbg7wSJY+Q== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,287,1596524400"; d="scan'208";a="485531097" Received: from orsmsx606.amr.corp.intel.com ([10.22.229.19]) by orsmga005.jf.intel.com with ESMTP; 21 Sep 2020 08:42:31 -0700 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX606.amr.corp.intel.com (10.22.229.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Mon, 21 Sep 2020 08:42:31 -0700 Received: from ORSEDG601.ED.cps.intel.com (10.7.248.6) by orsmsx601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5 via Frontend Transport; Mon, 21 Sep 2020 08:42:31 -0700 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (104.47.55.107) by edgegateway.intel.com (134.134.137.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.1713.5; Mon, 21 Sep 2020 08:42:31 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JPAsns7zne00XX+L7U8ncCO9Q6VbL4gLfXj67g5FBzmj565xz82jniz25yCFr5fkHdR25+8usYtYdzdc0Bx7v44wpL4qZpqN1ESaqNsQ837qx9mlbYrumsaMzOJziER31oJZ3cMb+7brbt1gYW3GZn5I7Qbm0JFNOktT+sKkT+IwkjT++ZcPL9yVG59ffvZ8nGyWMmw++JZgzwBKwNHOSVPcbuWpOrtWiccUdtKx14D0NvNgJ4lxlCarV7fwlJvPwIXWUD1ghmC0uWEkFGz7msjwNO/VLdPpHUX7pptAGHKKeZuXY9zHRUI4FWJ3APD9FwcW4ZgmrpcQmNH9Ulb4zA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=UC86h9Ik3XO2xZnZBCJEKQDr6RBMyliyXNm35z9csss=; b=QxSzZBnq1NXhN+TX6rKs7970Q44PJ34ov/CYlBuRpVXWV2IAKCsrQ1ld2jmomBrQMTfkWPtX46PcnRX3qYXDcZv79nVk1iK0BYAH7/BrUfuUiZP/RrZx0UyHgqafijHmbUJ97SecN5bEBv/DJRLniDgPpyOZAzh/kThmsAtsipTTndSfwHIqWQvPJO0s+sReLKy5fqULCXEtVrQ93GNiKqvGg3ZkzvH6pUQPRqzDytO7aXakr7R7IgmxxvURTIMV9ash8yftdpeg1T7OY+g5fnKJXxv2X0vHnMFyUjcJVqbzglNYfSs56UGryweNi3NyadxbHqq6T5Gqc+Q3+dQTlw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=UC86h9Ik3XO2xZnZBCJEKQDr6RBMyliyXNm35z9csss=; b=OTfwZ9H5WLTT38n7kTK7tw/3DQnPfPGr9Af2mU3xYv7Vb0yi5MKOP6X4a5mEsrTP33RVVmWM/hPFUrwt4bvsXJdhtocR8PDJZZkUIIj9e/ubbLMtanTPqurTh0Y7d4syNUP4So1bB4EW/V6ETbiN6BAWoV+xuf2bkcSGbp7/I0M= Received: from SN6PR11MB2574.namprd11.prod.outlook.com (2603:10b6:805:59::14) by SN6PR11MB3150.namprd11.prod.outlook.com (2603:10b6:805:d1::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3391.22; Mon, 21 Sep 2020 15:42:28 +0000 Received: from SN6PR11MB2574.namprd11.prod.outlook.com ([fe80::54:b143:c75e:41bd]) by SN6PR11MB2574.namprd11.prod.outlook.com ([fe80::54:b143:c75e:41bd%7]) with mapi id 15.20.3391.026; Mon, 21 Sep 2020 15:42:28 +0000 From: "Eads, Gage" To: Olivier Matz CC: "dev@dpdk.org" , "arybchenko@solarflare.com" , "Mcnamara, John" , "Kovacevic, Marko" Thread-Topic: [PATCH v3] doc: add stack mempool guide Thread-Index: AQHWjP5yazGam87C70OMxYIrVZbRK6lzO+8A Date: Mon, 21 Sep 2020 15:42:28 +0000 Message-ID: References: <20200811211015.29704-1-gage.eads@intel.com> <20200914211153.6725-1-gage.eads@intel.com> <20200917142530.GU21395@platinum> In-Reply-To: <20200917142530.GU21395@platinum> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.5.1.3 dlp-product: dlpe-windows dlp-reaction: no-action authentication-results: 6wind.com; dkim=none (message not signed) header.d=none;6wind.com; dmarc=none action=none header.from=intel.com; x-originating-ip: [68.203.30.51] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: acbb3854-e0d9-4233-bd5d-08d85e44f243 x-ms-traffictypediagnostic: SN6PR11MB3150: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:9508; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: Hgny0P5A5lP756AXIwhd7I/yNS9W4HJUzzhD+tYiPFMRjRyxVNpFftT6/eSLMNBRRqYnn1QKPCSKal9hNzCzqT1ScoGAfGWyqi88nNtUDchIn2nSer9miYlblt4x81dDwrqwIWddtuFhTraV1StDYqQf1ADXR71uqZASNMEcHVWwGL5pVufi0VrIk2pnQBdU3O4q9p8TdD7VLi5CZ8uM/51nI68TD+Gi2ZNcqU6AjnQhHX6NFuIkFV/qMq2VXblDUIKrzjUc+NPhHWlQmA+658dCJ9kRzeg7yqfyc4rlgmxhPeIJvrYCBJtVLC19ll09PsvsUzgTysS0xqhvT7MBJT0LFGNtZiLCKQgYeweIMyqoDThkP+XeJMhI1wzKyUMn x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SN6PR11MB2574.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(396003)(39860400002)(136003)(366004)(376002)(346002)(316002)(6916009)(8676002)(54906003)(478600001)(4326008)(8936002)(55016002)(66946007)(76116006)(33656002)(66476007)(64756008)(26005)(186003)(66556008)(66446008)(71200400001)(5660300002)(2906002)(52536014)(107886003)(7696005)(6506007)(86362001)(9686003); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: P/8M+bbEoOtqnN02mm5ImAcwKJzJ8j4bH9i6vRQsW0MQ9SwKPhdmTMYHJdBIvx3/GcE/j8KqTZCxpWcydaPIcxxS0Ybolp6anRki/Mx+3SR4obQa2gl5haq32Vorhek0bSmYwBqfQmKQjfQv0XL46p216w/ZEsOzSAXcQrf/f6K5oyLKTF/cjL7zY59kqZ7pjG04r+LKBOEghsi+952qpj7zbQy9fkZAp8Z5EzJRHRz5iIN6ahgW0TNyikoGyqlbqs1ReDL/cvaud4cFEbJCFgRIPpdb2cQCddmvBHqcoUHfg1t/0pLfGuDjpIX2+PrllzbAZDaj5SNDrhqa+WxrIqNgn9+n+4oq3D+axwtRq15CEASM9tDN1FFmta0wzk9AgPg2CiAX4MxO+Rz2wSv4yvgmtYYi3PpxosSpZESVCtvZ6jna4G/jeEkgzOJuGIluXUn7+UCbNzvoEjq8bkTguAV+FOWEk57Rn5j5hq1nLyopsc2Cm06dsRK5F3x6eM4H1X35qNUT1PSDc9JiE3VqSzm/30HX6qmEpiYFnH5FsZAL9qoKCVxf7+UA6nOVsviOkJpXjdtzDSkKSKJjiCyOTi56ZsSukCGIMbVr07U/ffKN5j6QAA+SmqBn1ACc2eXJEoGA7zZtAVCsZ6nzN3lfCw== Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SN6PR11MB2574.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: acbb3854-e0d9-4233-bd5d-08d85e44f243 X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Sep 2020 15:42:28.5049 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: YReZrvr6PLD78CHg6e3rYPbagXJREBOdGWfhKGqE6cMqg9OhfWw+MQFLe/kkHMyWO7qQ5W7K3Gy5v+7pO5WCxQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN6PR11MB3150 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH v3] doc: add stack mempool guide 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" Hi Olivier, > > +Stack Mempool Driver > > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > + > > +**rte_mempool_stack** is a pure software mempool driver based on the > > +``rte_stack`` DPDK library. A stack-based mempool is often better suit= ed to > > +packet-processing workloads than a ring-based mempool, since its LIFO > behavior > > +results in better temporal locality and a minimal memory footprint eve= n if the > > +mempool is over-provisioned. >=20 > Would it make sense to give an example of a use-case where the stack > driver should be used in place of the standard ring-based one? >=20 > In most run-to-completion applications, the mbufs stay in per-core > caches, so changing the mempool driver won't have a big impact. However, > I suspect that for applications using a pipeline model (ex: rx on core0, > tx on core1), the stack model would be more efficient. Is it something > that you measured? If yes, it would be useful to explain this in the > documentation. >=20 Good point, I was overlooking the impact of the per-core caches. I've seen = data showing better overall packet throughput with the stack mempool, and indeed that wa= s a pipelined application. How about this re-write? " **rte_mempool_stack** is a pure software mempool driver based on the ``rte_stack`` DPDK library. For run-to-completion workloads with sufficient= ly large per-lcore caches, the mbufs will likely stay in the per-lcore caches = and the mempool type (ring, stack, etc.) will have a negligible impact on performan= ce. However a stack-based mempool is often better suited to pipelined packet-processing= workloads (which allocate and free mbufs on different lcores) than a ring-based mempo= ol, since its LIFO behavior results in better temporal locality and a minimal memory foot= print even if the mempool is over-provisioned. Users are encouraged to benchmark with = multiple mempool types to determine which works best for their specific application. " Thanks, Gage