From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id F3B7143F44; Mon, 29 Apr 2024 08:21:14 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D6B7C402AB; Mon, 29 Apr 2024 08:21:14 +0200 (CEST) Received: from inbox.dpdk.org (inbox.dpdk.org [95.142.172.178]) by mails.dpdk.org (Postfix) with ESMTP id 3B4F44025C for ; Mon, 29 Apr 2024 08:21:14 +0200 (CEST) Received: by inbox.dpdk.org (Postfix, from userid 33) id 2C9B443F45; Mon, 29 Apr 2024 08:21:14 +0200 (CEST) From: bugzilla@dpdk.org To: dev@dpdk.org Subject: [DPDK/core Bug 1425] enable_stdatomic=true breaks C++ on GCC 11 and earlier Date: Mon, 29 Apr 2024 06:21:13 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: DPDK X-Bugzilla-Component: core X-Bugzilla-Version: 23.11 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mattias.ronnblom@ericsson.com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: Normal X-Bugzilla-Assigned-To: dev@dpdk.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: multipart/alternative; boundary=17143716730.4e4Df1.1379317 Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://bugs.dpdk.org/ Auto-Submitted: auto-generated X-Auto-Response-Suppress: All MIME-Version: 1.0 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 --17143716730.4e4Df1.1379317 Date: Mon, 29 Apr 2024 08:21:13 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.dpdk.org/ Auto-Submitted: auto-generated X-Auto-Response-Suppress: All https://bugs.dpdk.org/show_bug.cgi?id=3D1425 Bug ID: 1425 Summary: enable_stdatomic=3Dtrue breaks C++ on GCC 11 and earlier Product: DPDK Version: 23.11 Hardware: All OS: Linux Status: UNCONFIRMED Severity: normal Priority: Normal Component: core Assignee: dev@dpdk.org Reporter: mattias.ronnblom@ericsson.com Target Milestone: --- On GCC 11 and earlier, configuring enable_stdatomic=3Dtrue prevents the use= of all DPDK header files that directly or indirectly include from a C++ translation unit (e.g., app). includes , which in turn is not necessarily C++-compatible. --=20 You are receiving this mail because: You are the assignee for the bug.= --17143716730.4e4Df1.1379317 Date: Mon, 29 Apr 2024 08:21:13 +0200 MIME-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.dpdk.org/ Auto-Submitted: auto-generated X-Auto-Response-Suppress: All
Bug ID 1425
Summary enable_stdatomic=3Dtrue breaks C++ on GCC 11 and earlier
Product DPDK
Version 23.11
Hardware All
OS Linux
Status UNCONFIRMED
Severity normal
Priority Normal
Component core
Assignee dev@dpdk.org
Reporter mattias.ronnblom@ericsson.com
Target Milestone ---

On GCC 11 and earlier, configuring=
 enable_stdatomic=3Dtrue prevents the use of
all DPDK header files that directly or indirectly include <rte_stdatomic=
.h>
from a C++ translation unit (e.g., app).

<rte_stdatomic.h> includes <stdatomic.h>, which in turn is not =
necessarily
C++-compatible.
          


You are receiving this mail because:
  • You are the assignee for the bug.
=20=20=20=20=20=20=20=20=20=20
= --17143716730.4e4Df1.1379317-- From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id AB66143F4D; Tue, 30 Apr 2024 01:15:01 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4A242402A8; Tue, 30 Apr 2024 01:15:01 +0200 (CEST) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 0748140262; Tue, 30 Apr 2024 01:14:59 +0200 (CEST) Received: by linux.microsoft.com (Postfix, from userid 1086) id 4B316210FBC8; Mon, 29 Apr 2024 16:14:58 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 4B316210FBC8 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1714432498; bh=hBudyi2l2uXRsUN0+6cooKOUmtdRyGWLoovhzTP4WVU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=BOYTAK9mRNnhkJQv9KII9n39ZCU0I/CxqZDQaO6YtIkYQjMCuHwV4BIMi/OolKJD9 b+vVvYWBJ5UcuXPGI7qp1a9LrtfFBkCL5ji4rZ7LlwT8DPz7zCR7N+bO7W/46alHZO YaJ/dDFnP3DcpGK18SwxV01BLK701Nc61RXLKLQ4= Date: Mon, 29 Apr 2024 16:14:58 -0700 From: Tyler Retzlaff To: bugzilla@dpdk.org Cc: dev@dpdk.org Subject: Re: [DPDK/core Bug 1425] enable_stdatomic=true breaks C++ on GCC 11 and earlier Message-ID: <20240429231458.GB17852@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) 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 On Mon, Apr 29, 2024 at 06:21:13AM +0000, bugzilla@dpdk.org wrote: > https://bugs.dpdk.org/show_bug.cgi?id=1425 > > Bug ID: 1425 > Summary: enable_stdatomic=true breaks C++ on GCC 11 and > earlier > Product: DPDK > Version: 23.11 > Hardware: All > OS: Linux > Status: UNCONFIRMED > Severity: normal > Priority: Normal > Component: core > Assignee: dev@dpdk.org > Reporter: mattias.ronnblom@ericsson.com > Target Milestone: --- > > On GCC 11 and earlier, configuring enable_stdatomic=true prevents the use of > all DPDK header files that directly or indirectly include > from a C++ translation unit (e.g., app). > > includes , which in turn is not necessarily > C++-compatible. This is known but to add some information. C++ and enable_stdatomic=true for llvm and gcc are not currently supported. the combination will remain unsupported for C++ compilers that do not support -std=c++23 which is the first C++ standard that requires interoperability with C11 stdatomic.h When enable_stdatomic=true there are bugs/incorrect usages of atomic qualifier in casts that (even when using C++23) cause compilation failure. These are a fixable but are low priority without -std=c++23. Finally, the legacy atomics remain unconverted to stdatomic. This will cause enable_stdatomic=true not to build when using llvm (but not gcc) because llvm strictly enforces qualification when using atomic generics. > > -- > You are receiving this mail because: > You are the assignee for the bug. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 97FE243F56; Tue, 30 Apr 2024 22:06:13 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 360D340262; Tue, 30 Apr 2024 22:06:13 +0200 (CEST) Received: from mail.lysator.liu.se (mail.lysator.liu.se [130.236.254.3]) by mails.dpdk.org (Postfix) with ESMTP id 0B6994025C; Tue, 30 Apr 2024 22:06:12 +0200 (CEST) Received: from mail.lysator.liu.se (localhost [127.0.0.1]) by mail.lysator.liu.se (Postfix) with ESMTP id A7832849B; Tue, 30 Apr 2024 22:06:11 +0200 (CEST) Received: by mail.lysator.liu.se (Postfix, from userid 1004) id 9B2C7849A; Tue, 30 Apr 2024 22:06:11 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on hermod.lysator.liu.se X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=ALL_TRUSTED,AWL, T_SCC_BODY_TEXT_LINE autolearn=disabled version=4.0.0 X-Spam-Score: -1.3 Received: from [192.168.1.59] (h-62-63-215-114.A163.priv.bahnhof.se [62.63.215.114]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.lysator.liu.se (Postfix) with ESMTPSA id 5BC148506; Tue, 30 Apr 2024 22:06:09 +0200 (CEST) Message-ID: Date: Tue, 30 Apr 2024 22:06:08 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [DPDK/core Bug 1425] enable_stdatomic=true breaks C++ on GCC 11 and earlier To: Tyler Retzlaff , bugzilla@dpdk.org Cc: dev@dpdk.org References: <20240429231458.GB17852@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> Content-Language: en-US From: =?UTF-8?Q?Mattias_R=C3=B6nnblom?= In-Reply-To: <20240429231458.GB17852@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV using ClamSMTP 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 On 2024-04-30 01:14, Tyler Retzlaff wrote: > On Mon, Apr 29, 2024 at 06:21:13AM +0000, bugzilla@dpdk.org wrote: >> https://bugs.dpdk.org/show_bug.cgi?id=1425 >> >> Bug ID: 1425 >> Summary: enable_stdatomic=true breaks C++ on GCC 11 and >> earlier >> Product: DPDK >> Version: 23.11 >> Hardware: All >> OS: Linux >> Status: UNCONFIRMED >> Severity: normal >> Priority: Normal >> Component: core >> Assignee: dev@dpdk.org >> Reporter: mattias.ronnblom@ericsson.com >> Target Milestone: --- >> >> On GCC 11 and earlier, configuring enable_stdatomic=true prevents the use of >> all DPDK header files that directly or indirectly include >> from a C++ translation unit (e.g., app). >> >> includes , which in turn is not necessarily >> C++-compatible. > > This is known but to add some information. > Is it also documented? > C++ and enable_stdatomic=true for llvm and gcc are not currently > supported. the combination will remain unsupported for C++ compilers > that do not support -std=c++23 which is the first C++ standard that > requires interoperability with C11 stdatomic.h > > When enable_stdatomic=true there are bugs/incorrect usages of atomic > qualifier in casts that (even when using C++23) cause compilation > failure. These are a fixable but are low priority without -std=c++23. > > Finally, the legacy atomics remain unconverted to stdatomic. This will > cause enable_stdatomic=true not to build when using llvm (but not gcc) > because llvm strictly enforces qualification when using atomic generics. > OK, I see. It'll be a while until enable_stdatomic is usable outside Windows then, for generic builds. Am I right if I say that C++23-capable compilers/run-times are supposed to have a which interoperates with C++ even in C++11-mode? Or need the application be compiled as C++23. >> >> -- >> You are receiving this mail because: >> You are the assignee for the bug. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7178943F56; Tue, 30 Apr 2024 22:37:17 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4356C40262; Tue, 30 Apr 2024 22:37:17 +0200 (CEST) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 739AD4025C; Tue, 30 Apr 2024 22:37:15 +0200 (CEST) Received: by linux.microsoft.com (Postfix, from userid 1086) id C19AC21112E1; Tue, 30 Apr 2024 13:37:14 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com C19AC21112E1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1714509434; bh=nZ5/bB3V2ztsK149tEgQCWeX/16+Ff2U35c5HSTw+lA=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=eV0lr7MHRDVTcP7BgWxWgxDTZMFBtRUsQpuyvWV8DaM8VOCVEleG84MXrJOn8tzLS /8VeRBtBMmqP4i+Yljk+rMYQm6yc5kUd6/gZTApEBq+NwsDWOfP53jnxmL3fUEH/xM aLI7rhoRHyfEti4w1bB4C8edCLhsgdA/TK8R7VYA= Date: Tue, 30 Apr 2024 13:37:14 -0700 From: Tyler Retzlaff To: Mattias =?iso-8859-1?Q?R=F6nnblom?= Cc: bugzilla@dpdk.org, dev@dpdk.org Subject: Re: [DPDK/core Bug 1425] enable_stdatomic=true breaks C++ on GCC 11 and earlier Message-ID: <20240430203714.GA7142@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> References: <20240429231458.GB17852@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) 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 On Tue, Apr 30, 2024 at 10:06:08PM +0200, Mattias Rönnblom wrote: > On 2024-04-30 01:14, Tyler Retzlaff wrote: > >On Mon, Apr 29, 2024 at 06:21:13AM +0000, bugzilla@dpdk.org wrote: > >>https://bugs.dpdk.org/show_bug.cgi?id=1425 > >> > >> Bug ID: 1425 > >> Summary: enable_stdatomic=true breaks C++ on GCC 11 and > >> earlier > >> Product: DPDK > >> Version: 23.11 > >> Hardware: All > >> OS: Linux > >> Status: UNCONFIRMED > >> Severity: normal > >> Priority: Normal > >> Component: core > >> Assignee: dev@dpdk.org > >> Reporter: mattias.ronnblom@ericsson.com > >> Target Milestone: --- > >> > >>On GCC 11 and earlier, configuring enable_stdatomic=true prevents the use of > >>all DPDK header files that directly or indirectly include > >>from a C++ translation unit (e.g., app). > >> > >> includes , which in turn is not necessarily > >>C++-compatible. > > > >This is known but to add some information. > > > > Is it also documented? we don't document anything about C++ right now including minimum compiler requirements or -std. i agree we probably should, if i find cycles i'll see if i can provide some text. > > >C++ and enable_stdatomic=true for llvm and gcc are not currently > >supported. the combination will remain unsupported for C++ compilers > >that do not support -std=c++23 which is the first C++ standard that > >requires interoperability with C11 stdatomic.h > > >When enable_stdatomic=true there are bugs/incorrect usages of atomic > >qualifier in casts that (even when using C++23) cause compilation > >failure. These are a fixable but are low priority without -std=c++23. > > > >Finally, the legacy atomics remain unconverted to stdatomic. This will > >cause enable_stdatomic=true not to build when using llvm (but not gcc) > >because llvm strictly enforces qualification when using atomic generics. > > > > OK, I see. It'll be a while until enable_stdatomic is usable outside > Windows then, for generic builds. > > Am I right if I say that C++23-capable compilers/run-times are > supposed to have a which interoperates with C++ even > in C++11-mode? Or need the application be compiled as C++23. the application will need to be compiled with -std=C++23 though i think llvm does have a stdatomic.h that may work with lower -std, gcc does not last i checked. in general i think (as you found with _Generic) the compiler vendors are limiting leaking of C into C++ and vice versa where it is not explicitly intended to operate in one language or the other. i'll be looking into this more beyond 24.07 since there is work to do even consuming with msvc that is not upstream. > > >> > >>-- > >>You are receiving this mail because: > >>You are the assignee for the bug.