From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f51.google.com (mail-wm0-f51.google.com [74.125.82.51]) by dpdk.org (Postfix) with ESMTP id 6D0F995C8 for ; Tue, 2 Feb 2016 11:21:33 +0100 (CET) Received: by mail-wm0-f51.google.com with SMTP id p63so110366338wmp.1 for ; Tue, 02 Feb 2016 02:21:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:organization:user-agent :in-reply-to:references:mime-version:content-transfer-encoding :content-type; bh=fKuOBufePSleBhBcy0qSfFHIAen0nw8S99ZNDvzNHDs=; b=BUCLwBQ+iIgkOz1v/FwLaxXDxNthlcJTMFjln4sFjccjP2L4Q9O+47h1zUnA3CV8+F XkYOQVGxnmVUidmq27gFW2k0sQHM9R7PLzG93tdCHmDLszOOCCTpePht4/agzseC0dP7 CBm2WbUu71Gwu6IAr8z0ktnYdU9m6gqXiC5JOmZIcLJ8saSVXTR85BaLAFJzl5HerIhZ 2I1x4qg0qzBZ62EaPhTZCn2GAOffvTQAi33tW1rGmOCOgCmqJo8tg79+nAhEutOr29RK UyzPRz2TCHidkoTNX3ofgqfbxbTxijIA6h9TDhnXU8a26n84BQkvSYcuyTAS4HEryb2d 8c3g== 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=fKuOBufePSleBhBcy0qSfFHIAen0nw8S99ZNDvzNHDs=; b=jwIPBFyAWE9DYhLLQWJjfpAiTuo0U7HYyul3KqSPq8wYPSkBoOe31L5ScRNVzcZmuS Kb5c3sRGO5Z8g/53cLxLRYej1tE9eadwAKH81hNhUlgNRm2M9QGpuAGQpTiU3WC4SrlB HHuMQQCOXvQcvo4kxvEuxy9zHXRh39zz9PQuOvNt9W1P4RgxJ2k73QNQDNTMLxkBQsWk 28FowudOsJaEMDAL0MHJ27S9LfxTDQDZw4/p5yfGR2BKimIV58jqRMe8T0UED6Gt8YZF Whws43pju7C3iY2q6LrZ5DOX/rM9IXnz8bhdOOiKoORsYOj7jZ59A2m37tQ+GGa4fN+Z wixQ== X-Gm-Message-State: AG10YOQHJM2d/99cIiCEWQdF79tUORrg27LO4KXPtynrF2Qgv3CsBX3a30dORmQ43XfbBaaN X-Received: by 10.28.55.76 with SMTP id e73mr17721575wma.53.1454408493268; Tue, 02 Feb 2016 02:21:33 -0800 (PST) Received: from xps13.localnet (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by smtp.gmail.com with ESMTPSA id x6sm725394wje.38.2016.02.02.02.21.32 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 02 Feb 2016 02:21:32 -0800 (PST) From: Thomas Monjalon To: Ferruh Yigit Date: Tue, 02 Feb 2016 11:20:21 +0100 Message-ID: <1729554.7VcsXzVtRs@xps13> Organization: 6WIND User-Agent: KMail/4.14.10 (Linux/4.1.6-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <1453983623-20709-1-git-send-email-ferruh.yigit@intel.com> References: <5530206.lovNufpa2q@xps13> <1453983623-20709-1-git-send-email-ferruh.yigit@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org, Jan Viktorin Subject: Re: [dpdk-dev] [PATCH v2] eal: add architecture specific rte_cpuflags.c files 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: Tue, 02 Feb 2016 10:21:33 -0000 2016-01-28 12:20, Ferruh Yigit: > Move cpu_feature_table array from arch specific rte_cpuflags.h files to > new arch specific rte_cpuflags.c files. > > Main motivation is to escape from static variable declarations in > header files. cpu_feature_table has many copies in final binary, even > exist in some object files that does not use this variable at all. > > And this can be a sample to create architecture specific source files > and move some functions which are not performance sensitive from > architecture header files to source files. > > v2: > * rebased for DPDK2.3 (16.04) > * added arm arch > * renamed cpu_feature_table[] to rte_cpu_feature_table[] Applied, thanks. Now that we have some .c files for rte_cpuflags, I think some code may be changed. The function rte_cpu_get_features() and the struct feature_entry are really specific to each arch and used only by rte_cpu_get_flag_enabled(). So they can be moved in .c and be more specific (leaf/subleaf is unused for some archs). Then there is no reason to keep rte_cpu_get_flag_enabled() inline.