From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-SN1-obe.outbound.protection.outlook.com (mail-sn1nam01on0085.outbound.protection.outlook.com [104.47.32.85]) by dpdk.org (Postfix) with ESMTP id 9FC477260 for ; Mon, 22 Jan 2018 08:17:17 +0100 (CET) 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=thZeHWnbVvufOkO4qvCcuxdR85PuMRXHeGfKgBOix20=; b=dOO0vgyg6ZACixfrFtWM7xmVdClb8hqGw42Qe3UitBAvePtPlVL5WLVInN+40WBnMyTyTcc/3b1doTtbHu2wuAKEMOjn0bJPDhBjJ0dtp5DY3aJxkj75DTDY22UCuMrbKvHK8qFqxwzlRixDDaw6eE5i1zOQ3eppl8lGmkZV6ZQ= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from Pavan-LT (111.93.218.67) by MWHPR07MB3469.namprd07.prod.outlook.com (10.164.192.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.428.17; Mon, 22 Jan 2018 07:17:13 +0000 Date: Mon, 22 Jan 2018 12:46:52 +0530 From: Pavan Nikhilesh To: Herbert Guan , "jerin.jacob@caviumnetworks.com" , "bruce.richardson@intel.com" , harry.van.haaren@intel.com, "hemant.agrawal@nxp.com" Cc: "dev@dpdk.org" , nd Message-ID: <20180122071651.42q4moppnroivdbm@Pavan-LT> References: <20171219105338.198727-1-bruce.richardson@intel.com> <20180119182349.21935-1-pbhagavatula@caviumnetworks.com> <20180119182349.21935-2-pbhagavatula@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170609 (1.8.3) X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: SG2PR06CA0170.apcprd06.prod.outlook.com (10.175.208.24) To MWHPR07MB3469.namprd07.prod.outlook.com (10.164.192.20) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 238a5298-1317-4412-1408-08d561682a47 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4604075)(4534125)(4602075)(4627221)(201703031133081)(201702281549075)(2017052603307)(7153060)(7193020); SRVR:MWHPR07MB3469; X-Microsoft-Exchange-Diagnostics: 1; MWHPR07MB3469; 3:ddJnO3ZaFpFRQoIJxhUsZR4a61nvyWOHX1DHx9nnwv2k8uRjPwgWmq9A+Ve5Z1mOEFkoDlYg4C1BB8ABvjWqf3m3t2hPY5eYGTbmYNqoF9RlSETrQCkXPbvJVUTpedsRijCWUS+aHFpvV4aQy6OYHZsMRL7sF7CC8B6/C2bLKFSSgsL6RzyW5y4TjNSPgIBvww+Or4vFgiWdy76dE7jbgENKgjbhAzEG0+QwPQc3TQkNVZ9nvfiqjXh+tJePst6o; 25:c7PTSFsDoeTJF8sp1xY+MzVDAw73gHwaB0asAWBNWgjnCtsK5HDoG84NLFv5zHWOmik/HxYOWOiG/o6BJ/vhSsnkPxfJz+7/O2Ik98EWdoXyucNscOkKt6AByUgIXg0TKQ/j8oqfu8j13RPpWfIbmXDa1B/M9STAMavir0CfPsjtNYL5KJaRvqdsqlkXskWCcOo8OM6XU1o11Nz/tVmgTZacfRVzndWrhJRra+vN6AVOYy4OlihrMnMmr8ytLCbg5rXftNEcUgDOBJxKJT3OUCBUCOkoVYFdZOhkzHDlpzFKbWk4tRFPBauCIuy6vIVdy+uqo1o0hIIeFPwUZlZjoQ==; 31:pspcqN3s1RYYFcXQu3UwDf6+71NmYsvgHcdyaSpDyWVjDHh3XTLOsne/F6RzVJSNHjBDA9+1LVN1JlYgUj4Xd/3sXS0884HG2OjbomTlLY6gpkgwUCaVxiJ1sAhwDAsIcBpN8c2C+GWlEgoU6nDKWD+PHBqRQgx4fcbqi1dfbm1gA1N9XlN04Er6tI1nlgQHxkhli7Xo515FuYPGQXNbXSuqWMWUYerIOjeyjM99JuY= X-MS-TrafficTypeDiagnostic: MWHPR07MB3469: X-Microsoft-Exchange-Diagnostics: 1; MWHPR07MB3469; 20:GoOgab1bU5F/X+Zjr26MxgcJBIa7lxLsrutXd2MUcSqH92S5Kd6+Rb2pNSGCwaLaywlEZRkrqdg7fbYV2qpQa+ikpY/z0TRlqdmfJiZf0DPY626v5rNszGeSL0m/1K9ikDM+mkqK3JPey0ZGi3KXewcT+bPD9ov881adrVd8+jn9ZE/3lxjLyDb9WAgot+Y2P7S52rWnWc0DjfnLqZmksF139XODCyFhVXw2MUXSNbUZqbaabCZad+xV6SUgD1/Ar93uzhWfnjdth3pcCnwHvKzBrTGTRGCX8LrxAM9Y7xtjXXMUuSNvYJ4aEHecRAWjyhM5xTzK3eOGWuprNKJzNC2mWsJsQw4Zw1Zm4O2KalbToTk1e4K9EP/2nqkedL2ggoE0TuuJ/1fH3qm4n7nRbh5PTsRREhDAsd7SNYebkXx2EbYSeoQ9Sg6fOGEMglOeDAuD6KF3AtiRHAP/dI4qVy6alhsEKmX0rGtHcPD6alAcd6NguWsfNrxr3tDBkBKwrLWEmjMagnwtRzUOgmHn75+0gVvmlrjM5IpZDf9wnJfGIWtGUXcossxLF4UIHpRWLVqtqCCm8gGMeHhsp+CXTK5bumLZlrWYWRMUFSUksMQ= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(180628864354917)(185117386973197)(228905959029699); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040501)(2401047)(8121501046)(5005006)(3002001)(10201501046)(93006095)(3231023)(2400081)(944501161)(6041288)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(20161123564045)(20161123558120)(20161123560045)(6072148)(201708071742011); SRVR:MWHPR07MB3469; BCL:0; PCL:0; RULEID:(100000803101)(100110400095); SRVR:MWHPR07MB3469; X-Microsoft-Exchange-Diagnostics: 1; MWHPR07MB3469; 4:0kXVJkY3uQUgzej60PJDemmhmE88ZW1r2faIbWiNpeLqIT8I7Z/qxZd7D5VHxDcNk7JC54JVtiZz8v/awuTEE8DvE30KnHeUdju/ZRwVtffVNZKddkh3jbILvQYLFBU9McjHpt3dc2kqbij6cKVMJqYH597L9aA2WjV2e/22Lu1fc+dkVzx2pylyMX/h0SwqXIsLKdLCHvwR3QJQ60pstDLyzx5sb+CvnFmAYBjLCjWbP5VPuaXbx1UxgY3l3C8cu2Ai+puYdef9FGqZMU2b+yWZzg7HmKIabRMOFyekpzstpY5D5jbgor0M2ugm/hic+vvIWGxVrKzt8BrNdUvuAMKdtvXb81BMuOvvbi/OCksxOVb4Z9kOpir9E3VMOFw5 X-Forefront-PRVS: 0560A2214D X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(396003)(39380400002)(376002)(366004)(39850400004)(346002)(199004)(189003)(13464003)(51914003)(25786009)(33716001)(1076002)(6116002)(3846002)(8656006)(5009440100003)(23726003)(66066001)(58126008)(2950100002)(42882006)(6666003)(53936002)(305945005)(7736002)(26005)(105586002)(2501003)(50466002)(2201001)(83506002)(93886005)(110136005)(68736007)(6246003)(6496006)(59450400001)(16526018)(8676002)(72206003)(81156014)(81166006)(5660300001)(52116002)(478600001)(8936002)(76176011)(54906003)(316002)(2906002)(97736004)(47776003)(53546011)(386003)(4326008)(55016002)(33896004)(9686003)(106356001)(229853002)(16586007)(107986001)(42262002); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR07MB3469; H:Pavan-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; MWHPR07MB3469; 23:sQbC19QT5lC86PVLi4U2t15Wc/p/49oA7Ynw1llm1?= =?us-ascii?Q?2jnWmKgsp+MKHlC0+ltEfxssjW6Z8gayMcm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7glBrVht4GjGgluZgBXwc1v5XZc3p+CaJGgaPwFJKwGdNQueEQ9a8386NG1M/vZLuAHl1+mNeP5rymEzAN1rYm3jzw5neIN2B1jW/0Zht1znfKOLoO+QDE2fs548+/aGbsy6fMZKT6JbOKg=; 24:ZYiJKmvFFnECMkMixhj/FS/NKzGYUC1bFrV62Wiju1Bs0FxLVfLK6FTTBFUJPVpO5thZJ3JCjBZoKJA+awLdbF2OqqmxLZSu7lqJlzDj3X8=; 7:0kvcmxEkTiSfEImsAcUdadkRnPjSD84OqptoVE6NsHZu9te0jun4045y6y3FHKjvVhi7vJyY707myTVf897Fp20dVGDKc/owo4t8dAQBtUah8pdz8uylDG9Aw1VMtF/wQ65kPOeyO79DhgH7Je6243+/X25S8ar1SlcXhH7ZXmp/7RAfKxYftB5vdWQ7BLpk0tyKHVgysXKsutqHGlCnHVdee3zlp2JlajirRPQ5jesYVJi7B4zjuSbfJNJEpQSo SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Jan 2018 07:17:13.3462 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 238a5298-1317-4412-1408-08d561682a47 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR07MB3469 Subject: Re: [dpdk-dev] [PATCH v4 2/2] build: add support for detecting march on ARM 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, 22 Jan 2018 07:17:18 -0000 Hi Herbert, Thanks for the review, will add a default entry for generic arm. On Mon, Jan 22, 2018 at 05:52:36AM +0000, Herbert Guan wrote: > Hi, Pavan > > Please see my notes inline. > > Best regards, > Herbert > > > -----Original Message----- > > From: Pavan Nikhilesh [mailto:pbhagavatula@caviumnetworks.com] > > Sent: Saturday, January 20, 2018 2:24 > > To: jerin.jacob@caviumnetworks.com; bruce.richardson@intel.com; > > harry.van.haaren@intel.com; Herbert Guan ; > > hemant.agrawal@nxp.com > > Cc: dev@dpdk.org; Pavan Nikhilesh > > Subject: [dpdk-dev] [PATCH v4 2/2] build: add support for detecting march > > on ARM > > > > Added support for detecting march and mcpu by reading midr_el1 register. > > The implementer, primary part number values read can be used to figure out > > the underlying arm cpu. > > > > Signed-off-by: Pavan Nikhilesh > > --- > > +impl_0x43 = ['Cavium', flags_cavium, machine_args_cavium] > > There're only Cavimu args/flags defined, so other arm/arm64 platforms will fail at detecting. Can you add one entry for default? > > > + > > +dpdk_conf.set_quoted('RTE_TOOLCHAIN', 'gcc') > > +dpdk_conf.set('RTE_TOOLCHAIN_GCC', 1) > > dpdk_conf.set('RTE_FORCE_INTRINSICS', 1) -if cc.sizeof('void *') == 8 > > - dpdk_conf.set('RTE_CACHE_LINE_SIZE', 128) > > - dpdk_conf.set('RTE_ARCH_ARM64', 1) > > - dpdk_conf.set('RTE_ARCH_64', 1) > > -else > > + > > +if cc.sizeof('void *') != 8 > > dpdk_conf.set('RTE_CACHE_LINE_SIZE', 64) > > dpdk_conf.set('RTE_ARCH_ARM', 1) > > dpdk_conf.set('RTE_ARCH_ARMv7', 1) > > +else > > + dpdk_conf.set('RTE_CACHE_LINE_SIZE', 128) > > + dpdk_conf.set('RTE_ARCH_ARM64', 1) > > + dpdk_conf.set('RTE_ARCH_64', 1) > > + > > + if not meson.is_cross_build() > > + # The script returns ['Implementor', 'Variant', 'Architecture', > > + # 'Primary Part number', 'Revision'] > > + detect_vendor = find_program(join_paths( > > + meson.current_source_dir(), > > 'armv8_machine.py')) > > + cmd = run_command(detect_vendor.path()) > > + if cmd.returncode() != 0 > > + message('Using default armv8 config') > > + else > > + machine_args = [] # Clear previous machine args > > + cmd_output = cmd.stdout().strip().split(' ') > > + machine = get_variable('impl_' + cmd_output[0]) > > Script will fail for non-cavium Arm platforms. We need to check if cmd_output[0] is a known value in a list, otherwise should go to default entry. > > > + message('Implementor : ' + machine[0]) > > +