From patchwork Fri Aug 11 13:10:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Marchand X-Patchwork-Id: 130164 X-Patchwork-Delegate: david.marchand@redhat.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DA28843035; Fri, 11 Aug 2023 15:10:38 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C80DD42D3F; Fri, 11 Aug 2023 15:10:38 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id CF10740E03 for ; Fri, 11 Aug 2023 15:10:37 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1691759437; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pm6hD1gjtApgOilBdYNZCocTB2e8HY55TQMWn9/mFDU=; b=Pc9QFlnRTo7m0rzNAph0OEP2jd5od3gCxjYhGOIppwdqK8Hy6gf5zjO7DGm96y4Efm7VTn S44EG84Iz98ssNpu7YVquygvixpdXDsNS987sq3sRenS5uAjy1d0RZdBBr4Qr4J+QsF4gG 4+AGIZTycJcq6ubfkdOEmN7rvLqlFnI= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-684-96-vg_gOPfqoUBQcsPTFtw-1; Fri, 11 Aug 2023 09:10:35 -0400 X-MC-Unique: 96-vg_gOPfqoUBQcsPTFtw-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id C3C7A1881472; Fri, 11 Aug 2023 13:10:33 +0000 (UTC) Received: from dmarchan.redhat.com (unknown [10.39.192.23]) by smtp.corp.redhat.com (Postfix) with ESMTP id 035C3C5B8FC; Fri, 11 Aug 2023 13:10:32 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: roretzla@linux.microsoft.com, Bruce Richardson , Konstantin Ananyev Subject: [PATCH] build: move AVX512 check to x86 config Date: Fri, 11 Aug 2023 15:10:24 +0200 Message-ID: <20230811131024.2285366-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The AVX512 check only matters to x86 compilation with gcc. Move it where appropriate. Signed-off-by: David Marchand Acked-by: Bruce Richardson Acked-by: Bruce Richardson --- buildtools/meson.build | 3 --- {buildtools => config/x86}/binutils-avx512-check.py | 0 config/x86/meson.build | 3 +++ 3 files changed, 3 insertions(+), 3 deletions(-) rename {buildtools => config/x86}/binutils-avx512-check.py (100%) diff --git a/buildtools/meson.build b/buildtools/meson.build index e1c600e40f..266e727706 100644 --- a/buildtools/meson.build +++ b/buildtools/meson.build @@ -4,7 +4,6 @@ pkgconf = find_program('pkg-config', 'pkgconf', required: false) check_symbols = find_program('check-symbols.sh') ldflags_ibverbs_static = find_program('options-ibverbs-static.sh') -objdump = find_program('objdump', 'llvm-objdump') python3 = import('python').find_installation(required: false) if python3.found() @@ -18,8 +17,6 @@ map_to_win_cmd = py3 + files('map_to_win.py') sphinx_wrapper = py3 + files('call-sphinx-build.py') get_cpu_count_cmd = py3 + files('get-cpu-count.py') get_numa_count_cmd = py3 + files('get-numa-count.py') -binutils_avx512_check = (py3 + files('binutils-avx512-check.py') + - [objdump] + cc.cmd_array()) # select library and object file format pmdinfo = py3 + files('gen-pmdinfo-cfile.py') + [meson.current_build_dir()] diff --git a/buildtools/binutils-avx512-check.py b/config/x86/binutils-avx512-check.py similarity index 100% rename from buildtools/binutils-avx512-check.py rename to config/x86/binutils-avx512-check.py diff --git a/config/x86/meson.build b/config/x86/meson.build index 54345c4da3..b2315c051f 100644 --- a/config/x86/meson.build +++ b/config/x86/meson.build @@ -4,6 +4,9 @@ # get binutils version for the workaround of Bug 97 binutils_ok = true if is_linux or cc.get_id() == 'gcc' + objdump = find_program('objdump', 'llvm-objdump') + binutils_avx512_check = (py3 + files('binutils-avx512-check.py') + + [objdump] + cc.cmd_array()) binutils_ok = run_command(binutils_avx512_check, check: false).returncode() == 0 if not binutils_ok and cc.has_argument('-mno-avx512f') machine_args += '-mno-avx512f'