From patchwork Tue Oct 17 13:49:22 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 132756 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 73D7A4318A; Tue, 17 Oct 2023 15:49:39 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id ECC6842DE2; Tue, 17 Oct 2023 15:49:29 +0200 (CEST) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 86EED40ED2 for ; Tue, 17 Oct 2023 15:49:25 +0200 (CEST) Received: by linux.microsoft.com (Postfix, from userid 1086) id AB5A020B74C1; Tue, 17 Oct 2023 06:49:24 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com AB5A020B74C1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1697550564; bh=Yv22wtECnckDBtjejvpHagG3x6JHPepVYwUX1dLliPM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=iBiUZGkv0mdPoAjeKKg4gPpYxoan31IYmMKmXC1bIqInP/ur+unVV9ojn3XKhsdNw WsiMaIQz/IJHyyYHZ3w275PfNiXkNma99lH1dSWTT3wNiWK7JPsj+K3Epy5UZw0t8j IoFuXBfaLXlje2W16xowP+zpA42xokPnuEkK6doc= From: Tyler Retzlaff To: dev@dpdk.org Cc: david.marchand@redhat.com, Bruce Richardson , Tyler Retzlaff Subject: [PATCH v2 1/2] build: temporarily disable MSVC warnings Date: Tue, 17 Oct 2023 06:49:22 -0700 Message-Id: <1697550563-17532-2-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1697550563-17532-1-git-send-email-roretzla@linux.microsoft.com> References: <1697548427-10153-1-git-send-email-roretzla@linux.microsoft.com> <1697550563-17532-1-git-send-email-roretzla@linux.microsoft.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 Temporarily disable integer truncation and conversion warnings for MSVC to allow CI pipeline to be established. Signed-off-by: Tyler Retzlaff Acked-by: Bruce Richardson --- config/meson.build | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/config/meson.build b/config/meson.build index d56b0f9..0968351 100644 --- a/config/meson.build +++ b/config/meson.build @@ -36,6 +36,11 @@ if is_ms_compiler # the MSVC compiler regards as unsafe but are used by DPDK dpdk_conf.set('_CRT_SECURE_NO_WARNINGS', 1) + # temporarily disable msvc specific warnings + # - 4244 compiler detected conversion of integer to smaller type + # - 4267 compiler detected conversion of size_t to smaller type + add_project_arguments('/wd4244', '/wd4267', language: 'c') + # enable non-locking atomic operations add_project_arguments('/experimental:c11atomics', language: 'c') From patchwork Tue Oct 17 13:49:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 132755 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 405F94318A; Tue, 17 Oct 2023 15:49:28 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B7F8A40273; Tue, 17 Oct 2023 15:49:27 +0200 (CEST) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 7C82D40270 for ; Tue, 17 Oct 2023 15:49:25 +0200 (CEST) Received: by linux.microsoft.com (Postfix, from userid 1086) id B7D3420B74C2; Tue, 17 Oct 2023 06:49:24 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com B7D3420B74C2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1697550564; bh=5k/tooEfru0VqKbl49c8v4HdGrp90EVouoUmHq6AtaA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=p0S+0MbuOnyPid1hxCL1w1HotYs0MbYLPbnMmJ3seudnvF3TwH0tTD+PBfkNOwP53 pnLg3igVHPv8DVG2jBr+QipQ9c5HUYLni8YCNVBAOw3kFbLFdb+YjPntlMi/j+c8eg nWd7scwnzlABJ5IsSL9+pVvDSNIhmPKuBukDqY1Q= From: Tyler Retzlaff To: dev@dpdk.org Cc: david.marchand@redhat.com, Bruce Richardson , Tyler Retzlaff Subject: [PATCH v2 2/2] eal: disable standard c atomics support check for MSVC Date: Tue, 17 Oct 2023 06:49:23 -0700 Message-Id: <1697550563-17532-3-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1697550563-17532-1-git-send-email-roretzla@linux.microsoft.com> References: <1697548427-10153-1-git-send-email-roretzla@linux.microsoft.com> <1697550563-17532-1-git-send-email-roretzla@linux.microsoft.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 MSVC will define __STDC_NO_ATOMICS__ until versions of the compiler that support atomics is released. Currently we use the Preview version of the compiler so skip the test of __STDC_NO_ATOMICS__ avoiding failure. This is a temporary change until the required compiler is released publicly but allows us to establish the MSVC CI pipeline. Signed-off-by: Tyler Retzlaff --- lib/eal/include/rte_stdatomic.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/eal/include/rte_stdatomic.h b/lib/eal/include/rte_stdatomic.h index 8579e2d..7a081cb 100644 --- a/lib/eal/include/rte_stdatomic.h +++ b/lib/eal/include/rte_stdatomic.h @@ -12,9 +12,11 @@ #endif #ifdef RTE_ENABLE_STDATOMIC +#ifndef _MSC_VER #ifdef __STDC_NO_ATOMICS__ #error enable_stdatomic=true but atomics not supported by toolchain #endif +#endif #include