From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-DM3-obe.outbound.protection.outlook.com (mail-dm3nam03on0077.outbound.protection.outlook.com [104.47.41.77]) by dpdk.org (Postfix) with ESMTP id 44C2F1B6DB for ; Mon, 16 Oct 2017 14:04:54 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=do/vrRJxS2Q0CGf60RVZMvouKLaXRyr5+9UorOFASTs=; b=Aj5cg5jZv3XS+s3Jb3+oe/kw5wQ3Shhy8Kz4OOgzRzKXQiSWdZUDArBIgq8eJcgeJZeKlohtFhLzYj6+90frhoxVvRTyPLYgdXBTd1jG/IfWlbtDbbvnrYVQ0iiCdV0+lbMWK0Xt0l+unBnmS8VNN3a1PKhntwChmn/xasBD5uU= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from PBHAGAVATULA-LT (111.93.218.67) by DM5PR07MB3466.namprd07.prod.outlook.com (10.164.153.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Mon, 16 Oct 2017 12:04:52 +0000 Date: Mon, 16 Oct 2017 17:34:37 +0530 From: Pavan Nikhilesh Bhagavatula To: "Carrillo, Erik G" Cc: dev@dpdk.org Message-ID: <20171016120436.GA20698@PBHAGAVATULA-LT> References: <20170817161104.24293-1-jerin.jacob@caviumnetworks.com> <1506093431-57588-1-git-send-email-erik.g.carrillo@intel.com> <20171003143723.GB10493@jerin> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: CY4PR03CA0096.namprd03.prod.outlook.com (10.171.242.165) To DM5PR07MB3466.namprd07.prod.outlook.com (10.164.153.21) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c7ebc4bc-b089-4bb7-6bd7-08d5148e1c41 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254152)(2017052603199)(201703131423075)(201703031133081)(201702281549075); SRVR:DM5PR07MB3466; X-Microsoft-Exchange-Diagnostics: 1; DM5PR07MB3466; 3:k5sJLaqZGZQ71N5RtY7isgHVLv+voIItw0Kb2KKjNBLzhIWg4ftgTFA2DGV8RT/NKqwsDqxtdXumW4UgSfYx4E4Mdyw3p215lWMrtHzK/yo1fwQ8e1XHvB3iSa8zGfq/TXDUXFq+MmRq+ueWR14wmEbBpj4u+vKbXWGH8S9iFUDWfDEqlUyoFKFEqMf+86ZR5jyHlA+VJUQtQxn5MwTtRvjLmRZmI3GLvcIJygvb7nqVfbhKsbOfnHK8fmGTyKv8; 25:eA+s4ROVitXxBxUtobc9i5qrmdfEV+aHkR9lsDjENea4zeTfDdhyyafmsntOj+msENUFrqfqXo+9qLt1B34C2DSVPidL1cUW1M7m/wKhUmiptU7I5+5V0BI2UzQziFJahuu8fIYwF30h2IcoEUx5Q57CGzdGbg8zMDqoiQZBrcpmiYQbGxnpZ+iAGbmyXJnFpENLWbT3ChAMNYbZHrdzdm30xveq1qIUDzdI7JrMyXWpXgXWWBCN4tWJAZ6DcR282RJAdkA+udDvAnDoIaNm/yf5qJwdiH3y37Cve6wQNkVWQiRl5x+h7W2CV6wSbdyXFEKeScfpH+J+iECsVz1rB9GPZDrodHnsdcCk6el7ix0=; 31:twM5umaNC5Dl/+29ooPJJmyjWXQC6edm8X+wTkYEuNpIEp6RwQ2tT8m6Ym2Hzz/ND5T90k2j8yCJe0rVMjnxGPaRFJk7/CmArTr42OMsj1hkdLF67JKdqKdW67yjkct0blHkTmloSKNENOLVpR4xJj4mjNlHOs6BkJutue0uNAck22CDRSa0PfMgiTMwH+yt0ZDy2PruwCA44DfvxfYL9gDg8rBKZTM1r0PjY4aMqik= X-MS-TrafficTypeDiagnostic: DM5PR07MB3466: X-Microsoft-Exchange-Diagnostics: 1; DM5PR07MB3466; 20:7ehRcqmxqhcKsjiTqRpNfeF+mBoMz7YPHBuV1uoWfocVEHLfdnCS9tBUJxFxEcDR5o+kLpJRUIwH0TQu9mpy4D5u1Fk8+n15IrwCqdjhUN1DaV4+6gwneq3MBil50Hy4qS93jYWlnszZ8wyISq+Xa5wK3RXOOjhHKpzesmyiUE6C2pAyy+v9QmrJGbEqdHuGxdT5It/vm6ZmIZm02AXLX2VbR/fP8jagbQQlDQ8fz4/ZZ7cdYqQ3jvD5bYib24SHFAQ3oLzF4i6ps097EuU8ECe9dZh8fAundIGfJSUzs+49sM/yfqICOMchoGLZxGWwDSc5pMzNnvemWVfoMc2+St9c64b2V5x9P7aXaLaNXIO3ZT39cyFYuFB9KAIkZT/1QCj20Bva2qrXJDCygTN4S/ecw8SjL751YJNHxvGWzFHRm3/Lbsige9IOnGir6uYdOVwHpmDjRw+ORgn57j8GzW02kaUkz4A3XuzRx8PHnN3b/Q/+GbjJHU3Aw/qLDsV8Hl7vHyG504GMj5hZy4nyjBiAjAIeQJqxfdOhYCZNVNsXoOnv407bLigw6cTnt9O40TSHSDITRvs1YzGJHt05fqexFRupDIlCYkT23q926V4=; 4:SbDFp5SWoyVfLBMyp85EGxAil/YRyJF16haLpBXZE0iOyLi6ozagreabmuKCKSlN9jsRe9kiy4BdZd1p+gUk4sB9Z1x7rLMYyUzGLJVGbPC7XDnO98D7rkIOYaoMoU2M5MXohBloUqFGnfWEJC8SUWbQsym661GgcE1ofNvm5RMOUwQ325LGo0qVplmHwBNnPOdQshp2N3SZP00ZemvvBzMLm/KyCbfGUUbADBVQY2UpDfi+iX7/BmH/pDt1HrTrkn7sxhz+wIpB1za730ZKw0oOX/ewLLAMrLhEIitumIw= X-Exchange-Antispam-Report-Test: UriScan:(788757137089); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(5005006)(8121501046)(10201501046)(3002001)(100000703101)(100105400095)(93006095)(6041248)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123555025)(20161123562025)(20161123558100)(20161123564025)(20161123560025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DM5PR07MB3466; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DM5PR07MB3466; X-Forefront-PRVS: 0462918D61 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(346002)(376002)(199003)(189002)(24454002)(81166006)(81156014)(8676002)(9686003)(55016002)(316002)(68736007)(8936002)(6246003)(53936002)(66066001)(16586007)(54356999)(72206003)(50466002)(58126008)(97736004)(229853002)(6916009)(33716001)(42882006)(2950100002)(478600001)(76176999)(47776003)(50986999)(6666003)(33656002)(101416001)(23726003)(6116002)(3846002)(1076002)(16526018)(93886005)(6496005)(5009440100003)(5660300001)(4326008)(189998001)(83506001)(305945005)(105586002)(7736002)(106356001)(25786009)(2906002)(18370500001)(107986001)(217873001); DIR:OUT; SFP:1101; SCL:1; SRVR:DM5PR07MB3466; H:PBHAGAVATULA-LT; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM5PR07MB3466; 23:sOYGIiHDqSrPr2YDD/jmuKkckRg563JOh5blzgqMb?= =?us-ascii?Q?lxdgNOCWb2WD9Rnu/N8z+yn2f/mXalaWyov3yvSp2sS+jVRnoGzjXHE65WTt?= =?us-ascii?Q?bWHIqw5IZOCNzAnN2bzV25co2G5KTYOF6smpCy7ZaRQz+0Q/Ni5swcYtKvyL?= =?us-ascii?Q?HMccGlCX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1TaL2z5gHNFmi6s4jIAhwJ+HwplLW4PYRaEt+gcKp5ipgA08r0PE6K3+ovJSHTJrV6BD9Q/kPss79ZvgB3/XH6voBHrGQMFx7FDJIrg3ptcOKVPEruUYqucszWInYztwRlj3WfNBt2VVvFfeEWNH0DmxLAZVCLYfmwA= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2017 12:04:52.2254 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR07MB3466 Subject: Re: [dpdk-dev] [RFC PATCH v2 0/1] eventtimer: introduce event timer adapter 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: , X-List-Received-Date: Mon, 16 Oct 2017 12:04:55 -0000 On Mon, Oct 09, 2017 at 08:30:35PM +0000, Carrillo, Erik G wrote: > > > > > > The second big change is to replace API parameters specifying pointer > > > to rte_event_timer_adapter with ids, which seems more common > > > throughout DPDK. > > > > > > Other changes include: > > > - removed rte_event_timer_adapter_lookup() function, since APIs no > > longer > > > accept pointer to rte_event_timer_adapter > > > > There is one difference between ethdev rx adapter, where we have > > rte_event_timer_arm_burst(), rte_event_timer_arm_tmo_tick_burst(), > > rte_event_timer_cancel_burst(), > > APIs in fastpath. So any multi process scheme where resolving the fastpath > > API functions in _one_ or zero redirection is fine. > > I see, makes sense. > > > > > I guess in we may need 2 or 3 indirection to resolve the fastpath functions > > with id scheme. Please choose scheme with one 1 or no redirection. > > I think, > > - By allocating adapter memory from the heap and > > Just to check, are you talking about the heap (e.g., rte_malloc) in hugepage memory? Yes, If we use rte_memzone_reserve and create the adapter in the primary process, the name can be used to do a lookup in the secondary. > > > - adapter hold the function pointers for multi process and > > - mempool kind of pointer object scheme without id and lookup() Can > > resolve function pointers without any indirection. > > > > Can you elaborate here? In the mempool implementation, it looks like there's a per-process array of ops objects, and each mempool instance has an index into the array that it uses to select the ops object to call through. Since the ops structures are initialized per-process, they get function pointers valid in that process - which relates to the second point above. If the adapter holds function pointers for a primary process (for example), they'll be invalid in the secondary. Am I missing something? > Once adapter is created using memzone in the Primary process, the secondary process can use the memzone name to get the pointer to the adapter and use data such as ops_id stored in the memzone to fixup the fastpath function pointers. The slowpath could still use ops_id based function pointers(mempool). > Thanks, > Gabriel > > > So please analyze on those lines as well. > > > > > Pavan