From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id E7286B54D for ; Sun, 15 Feb 2015 07:01:49 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga101.fm.intel.com with ESMTP; 14 Feb 2015 22:01:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.09,579,1418112000"; d="scan'208";a="685918487" Received: from kmsmsx151.gar.corp.intel.com ([172.21.73.86]) by orsmga002.jf.intel.com with ESMTP; 14 Feb 2015 22:01:47 -0800 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by KMSMSX151.gar.corp.intel.com (172.21.73.86) with Microsoft SMTP Server (TLS) id 14.3.195.1; Sun, 15 Feb 2015 14:01:46 +0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.62]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.46]) with mapi id 14.03.0195.001; Sun, 15 Feb 2015 14:01:44 +0800 From: "Liang, Cunming" To: Neil Horman Thread-Topic: [dpdk-dev] [PATCH v6 06/19] eal: new TLS definition and API declaration Thread-Index: AQHQRy3RZW1DjWqShEOxdOHLm0lqv5zuFbeAgALPPtD//8PTAIAAkbpA Date: Sun, 15 Feb 2015 06:01:45 +0000 Message-ID: References: <1423728996-3004-1-git-send-email-cunming.liang@intel.com> <1423791501-1555-1-git-send-email-cunming.liang@intel.com> <1423791501-1555-7-git-send-email-cunming.liang@intel.com> <20150213135807.GC13495@neilslaptop.think-freely.org> <20150215051700.GA4534@neilslaptop.think-freely.org> In-Reply-To: <20150215051700.GA4534@neilslaptop.think-freely.org> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCH v6 06/19] eal: new TLS definition and API declaration 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: Sun, 15 Feb 2015 06:01:50 -0000 > -----Original Message----- > From: Neil Horman [mailto:nhorman@tuxdriver.com] > Sent: Sunday, February 15, 2015 1:17 PM > To: Liang, Cunming > Cc: dev@dpdk.org > Subject: Re: [dpdk-dev] [PATCH v6 06/19] eal: new TLS definition and API > declaration > [...]=20 > > > > > > > > RTE_DEFINE_PER_LCORE(unsigned, _lcore_id); > > > > +RTE_DEFINE_PER_LCORE(unsigned, _socket_id); > > > > +RTE_DEFINE_PER_LCORE(rte_cpuset_t, _cpuset); > > > > > > > > /* > > > > * Send a message to a slave lcore identified by slave_id to call = a > > > > -- > > > > 1.8.1.4 > > > > > > > > > > > All of these exported functions need to be exported in the version ma= p. Also, > I > > > don't think its a good idea to simply expose the per lcore cpuset var= iables. It > > > would be far better to create an api around them > > [LCM] Thanks for the remind, I haven't taken care of the version map. > > The rte_thread_set/get_affinity() are the api around _cpuset, so do you > suggest we don't put 'per_lcore__cpuset' into rte_eal_version.map ? > > On this point, I agree with you and think we'd better not expose > 'per_lcore__socket_id' as well, what do you think ? > Yes, absolutely, you should wrap some API around them, and make them > defined > symbols, only inline them if they're going to be in the hot path. [LCM] _socket_id is wrapped by rte_socket_id() and rte_thread_set_affinity(= ). rte_socket_id() is defined as inline in rte_lcore.h. So finally two (rte_th= read_set/get_affinity()) are added into version map. All these are updated in v7. >=20 > Thanks > Neil >=20 > > > > > > Neil > > > >