diff mbox series

doc: announce adoption of C11 atomic operations semantics

Message ID 1588835193-27550-1-git-send-email-phil.yang@arm.com
State New
Headers show
Series doc: announce adoption of C11 atomic operations semantics | expand

Commit Message

Phil Yang May 7, 2020, 7:06 a.m. UTC
From: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>


As agreed in the DPDK tech board [1], after 20.05 release, patches must
use C11 atomic operations semantics with the help of wrappers.

[1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

Reviewed-by: Phil Yang <phil.yang@arm.com>

Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>

---
 doc/guides/rel_notes/deprecation.rst | 12 ++++++++++++
 1 file changed, 12 insertions(+)

-- 
2.7.4

Comments

Stephen Hemminger May 7, 2020, 9 p.m. UTC | #1
On Thu,  7 May 2020 15:06:33 +0800
Phil Yang <phil.yang@arm.com> wrote:

> From: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> 

> As agreed in the DPDK tech board [1], after 20.05 release, patches must

> use C11 atomic operations semantics with the help of wrappers.

> 

> [1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

> 

> Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> Reviewed-by: Phil Yang <phil.yang@arm.com>

> Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>


The use of Gcc __sync_ primitives should also be replaced with C11 atomic.
Honnappa Nagarahalli May 8, 2020, 3:46 a.m. UTC | #2
<snip>

> Subject: Re: [PATCH] doc: announce adoption of C11 atomic operations

> semantics

> 

> On Thu,  7 May 2020 15:06:33 +0800

> Phil Yang <phil.yang@arm.com> wrote:

> 

> > From: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> >

> > As agreed in the DPDK tech board [1], after 20.05 release, patches

> > must use C11 atomic operations semantics with the help of wrappers.

> >

> > [1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

> >

> > Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> > Reviewed-by: Phil Yang <phil.yang@arm.com>

> > Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>

> 

> The use of Gcc __sync_ primitives should also be replaced with C11 atomic.

Agree, not sure if this should be added to the deprecation list. But, will add it to checkpatches.sh
Honnappa Nagarahalli May 21, 2020, 4:31 a.m. UTC | #3
<snip>

> Subject: [PATCH] doc: announce adoption of C11 atomic operations semantics

> 

> From: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> 

> As agreed in the DPDK tech board [1], after 20.05 release, patches must use

> C11 atomic operations semantics with the help of wrappers.

> 

> [1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

As noted in the minutes, this has been approved in the tech-board. Can I get some ACKs for this patch?

> 

> Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> Reviewed-by: Phil Yang <phil.yang@arm.com>

> Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>

> ---

>  doc/guides/rel_notes/deprecation.rst | 12 ++++++++++++

>  1 file changed, 12 insertions(+)

> 

> diff --git a/doc/guides/rel_notes/deprecation.rst

> b/doc/guides/rel_notes/deprecation.rst

> index 20aa745..208708d 100644

> --- a/doc/guides/rel_notes/deprecation.rst

> +++ b/doc/guides/rel_notes/deprecation.rst

> @@ -113,3 +113,15 @@ Deprecation Notices

>    Python 2 support will be completely removed in 20.11.

>    In 20.08, explicit deprecation warnings will be displayed when running

>    scripts with Python 2.

> +

> +* rte_atomicNN_xxx: These APIs do not take memory order parameter. This

> +does

> +  not allow for writing optimized code for all the CPU architectures

> +supported

> +  in DPDK. DPDK will adopt C11 atomic operations semantics and provide

> +wrappers

> +  using C11 atomic built-ins. These wrappers must be used for patches

> +that

> +  need to be merged in 20.08 onwards.

> +

> +* rte_smp_*mb: These APIs provide full barrier functionality. However,

> +many

> +  use cases do not require full barriers. To support such use cases,

> +DPDK will

> +  adopt C11 barrier semantics and provide wrappers using C11 atomic built-

> ins.

> +  These wrappers must be used for patches that need to be merged in

> +20.08

> +  onwards.

> --

> 2.7.4
Jerin Jacob May 21, 2020, 4:56 a.m. UTC | #4
On Thu, May 7, 2020 at 12:38 PM Phil Yang <phil.yang@arm.com> wrote:
>

> From: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

>

> As agreed in the DPDK tech board [1], after 20.05 release, patches must

> use C11 atomic operations semantics with the help of wrappers.

>

> [1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

>

> Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> Reviewed-by: Phil Yang <phil.yang@arm.com>

> Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>



Acked-by: Jerin Jacob <jerinj@marvell.com>




> ---

>  doc/guides/rel_notes/deprecation.rst | 12 ++++++++++++

>  1 file changed, 12 insertions(+)

>

> diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst

> index 20aa745..208708d 100644

> --- a/doc/guides/rel_notes/deprecation.rst

> +++ b/doc/guides/rel_notes/deprecation.rst

> @@ -113,3 +113,15 @@ Deprecation Notices

>    Python 2 support will be completely removed in 20.11.

>    In 20.08, explicit deprecation warnings will be displayed when running

>    scripts with Python 2.

> +

> +* rte_atomicNN_xxx: These APIs do not take memory order parameter. This does

> +  not allow for writing optimized code for all the CPU architectures supported

> +  in DPDK. DPDK will adopt C11 atomic operations semantics and provide wrappers

> +  using C11 atomic built-ins. These wrappers must be used for patches that

> +  need to be merged in 20.08 onwards.

> +

> +* rte_smp_*mb: These APIs provide full barrier functionality. However, many

> +  use cases do not require full barriers. To support such use cases, DPDK will

> +  adopt C11 barrier semantics and provide wrappers using C11 atomic built-ins.

> +  These wrappers must be used for patches that need to be merged in 20.08

> +  onwards.

> --

> 2.7.4

>
Hemant Agrawal May 21, 2020, 5:04 a.m. UTC | #5
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Ananyev, Konstantin May 21, 2020, 10:33 a.m. UTC | #6
> >

> > As agreed in the DPDK tech board [1], after 20.05 release, patches must

> > use C11 atomic operations semantics with the help of wrappers.

> >

> > [1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

> >

> > Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> > Reviewed-by: Phil Yang <phil.yang@arm.com>

> > Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>

> 

> > ---

> >  doc/guides/rel_notes/deprecation.rst | 12 ++++++++++++

> >  1 file changed, 12 insertions(+)

> >

> > diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst

> > index 20aa745..208708d 100644

> > --- a/doc/guides/rel_notes/deprecation.rst

> > +++ b/doc/guides/rel_notes/deprecation.rst

> > @@ -113,3 +113,15 @@ Deprecation Notices

> >    Python 2 support will be completely removed in 20.11.

> >    In 20.08, explicit deprecation warnings will be displayed when running

> >    scripts with Python 2.

> > +

> > +* rte_atomicNN_xxx: These APIs do not take memory order parameter. This does

> > +  not allow for writing optimized code for all the CPU architectures supported

> > +  in DPDK. DPDK will adopt C11 atomic operations semantics and provide wrappers

> > +  using C11 atomic built-ins. These wrappers must be used for patches that

> > +  need to be merged in 20.08 onwards.

> > +

> > +* rte_smp_*mb: These APIs provide full barrier functionality. However, many

> > +  use cases do not require full barriers. To support such use cases, DPDK will

> > +  adopt C11 barrier semantics and provide wrappers using C11 atomic built-ins.

> > +  These wrappers must be used for patches that need to be merged in 20.08

> > +  onwards.

> > --


Can we probably add a note that new API supposed to not introduce
performance degradation comparing to one we are going to deprecate?
Thanks
Konstantin
David Christensen May 21, 2020, 7:34 p.m. UTC | #7
On 5/7/20 12:06 AM, Phil Yang wrote:
> From: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> 

> As agreed in the DPDK tech board [1], after 20.05 release, patches must

> use C11 atomic operations semantics with the help of wrappers.

> 

> [1] http://mails.dpdk.org/archives/dev/2020-April/165143.html

> 

> Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>

> Reviewed-by: Phil Yang <phil.yang@arm.com>

> Reviewed-by: Ruifeng Wang <ruifeng.wang@arm.com>


Acked-by: David Christensen <drc@linux.vnet.ibm.com>
diff mbox series

Patch

diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst
index 20aa745..208708d 100644
--- a/doc/guides/rel_notes/deprecation.rst
+++ b/doc/guides/rel_notes/deprecation.rst
@@ -113,3 +113,15 @@  Deprecation Notices
   Python 2 support will be completely removed in 20.11.
   In 20.08, explicit deprecation warnings will be displayed when running
   scripts with Python 2.
+
+* rte_atomicNN_xxx: These APIs do not take memory order parameter. This does
+  not allow for writing optimized code for all the CPU architectures supported
+  in DPDK. DPDK will adopt C11 atomic operations semantics and provide wrappers
+  using C11 atomic built-ins. These wrappers must be used for patches that
+  need to be merged in 20.08 onwards.
+
+* rte_smp_*mb: These APIs provide full barrier functionality. However, many
+  use cases do not require full barriers. To support such use cases, DPDK will
+  adopt C11 barrier semantics and provide wrappers using C11 atomic built-ins.
+  These wrappers must be used for patches that need to be merged in 20.08
+  onwards.