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 06E76A0352; Mon, 23 Dec 2019 11:38:59 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 6A1181C01; Mon, 23 Dec 2019 11:38:58 +0100 (CET) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by dpdk.org (Postfix) with ESMTP id 7A5EA1F5 for ; Mon, 23 Dec 2019 11:38:57 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Dec 2019 02:38:56 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,347,1571727600"; d="scan'208";a="391548316" Received: from silpixa00399126.ir.intel.com (HELO silpixa00399126.ger.corp.intel.com) ([10.237.223.2]) by orsmga005.jf.intel.com with ESMTP; 23 Dec 2019 02:38:55 -0800 From: Bruce Richardson To: david.marchand@redhat.com Cc: dev@dpdk.org, Bruce Richardson Date: Mon, 23 Dec 2019 10:38:40 +0000 Message-Id: <20191223103840.2848732-1-bruce.richardson@intel.com> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20191217140838.2711906-1-bruce.richardson@intel.com> References: <20191217140838.2711906-1-bruce.richardson@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v2] build: explicitly enable sse4 for meson builds 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" If the compiler does not recognise the specific CPU when building with the default "native" machine type, sse4.2 instructions can be missing, causing a build error. Rather than advising the user to change the machine type, we can just turn on SSE4.2 directly. This can prevent issues with running automated tests with older compilers/distros on newer hardware. Signed-off-by: Bruce Richardson --- V2: insert missing quotes around "-msse4" --- config/x86/meson.build | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/config/x86/meson.build b/config/x86/meson.build index 8b0fa3e6f..adc857ba2 100644 --- a/config/x86/meson.build +++ b/config/x86/meson.build @@ -15,11 +15,9 @@ if not is_windows endif # we require SSE4.2 for DPDK -sse_errormsg = '''SSE4.2 instruction set is required for DPDK. -Please set the machine type to "nehalem" or "corei7" or higher value''' - if cc.get_define('__SSE4_2__', args: machine_args) == '' - error(sse_errormsg) + message('SSE 4.2 not enabled by default, explicitly enabling') + machine_args += '-msse4' endif base_flags = ['SSE', 'SSE2', 'SSE3','SSSE3', 'SSE4_1', 'SSE4_2'] -- 2.24.1