public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely.gcc@gmail.com>
To: Jason Merrill <jason@redhat.com>
Cc: gcc-patches List <gcc-patches@gcc.gnu.org>,
	 "Richard Earnshaw (lists)" <Richard.Earnshaw@arm.com>,
	"libstdc++" <libstdc++@gcc.gnu.org>,
	 GNU C Library <libc-alpha@sourceware.org>
Subject: Re: [PATCH] c++: implement C++17 hardware interference size
Date: Fri, 16 Jul 2021 14:26:42 +0100	[thread overview]
Message-ID: <CAH6eHdSot60bjJTNWvXzHOLzNjasDpEK2TrXSM=csrN_==GZhg@mail.gmail.com> (raw)
In-Reply-To: <CADzB+2ktqA=nzYS5zJAxH9TfFexP-OzZw8SoPOd907-qxVbWpg@mail.gmail.com>

On Fri, 16 Jul 2021 at 03:42, Jason Merrill via Libstdc++
<libstdc++@gcc.gnu.org> wrote:
> > diff --git a/libstdc++-v3/include/std/version
> > b/libstdc++-v3/include/std/version
> > index 27bcd32cb60..d5e155db48b 100644
> > --- a/libstdc++-v3/include/std/version
> > +++ b/libstdc++-v3/include/std/version
> > @@ -140,6 +140,9 @@
> >  #define __cpp_lib_filesystem 201703
> >  #define __cpp_lib_gcd 201606
> >  #define __cpp_lib_gcd_lcm 201606
> > +#ifdef __GCC_DESTRUCTIVE_SIZE
> > +# define __cpp_lib_hardware_interference_size 201703L
> > +#endif
> >  #define __cpp_lib_hypot 201603
> >  #define __cpp_lib_invoke 201411L
> >  #define __cpp_lib_lcm 201606
> > diff --git a/libstdc++-v3/libsupc++/new b/libstdc++-v3/libsupc++/new
> > index 3349b13fd1b..7bc67a6cb02 100644
> > --- a/libstdc++-v3/libsupc++/new
> > +++ b/libstdc++-v3/libsupc++/new
> > @@ -183,9 +183,9 @@ inline void operator delete[](void*, void*)
> > _GLIBCXX_USE_NOEXCEPT { }
> >  } // extern "C++"
> >
> >  #if __cplusplus >= 201703L
> > -#ifdef _GLIBCXX_HAVE_BUILTIN_LAUNDER
> >  namespace std
> >  {
> > +#ifdef _GLIBCXX_HAVE_BUILTIN_LAUNDER
> >  #define __cpp_lib_launder 201606
> >    /// Pointer optimization barrier [ptr.launder]
> >    template<typename _Tp>
> > @@ -205,8 +205,14 @@ namespace std
> >    void launder(const void*) = delete;
> >    void launder(volatile void*) = delete;
> >    void launder(const volatile void*) = delete;
> > -}
> >  #endif // _GLIBCXX_HAVE_BUILTIN_LAUNDER
> > +
> > +#ifdef __GCC_DESTRUCTIVE_SIZE
> > +# define __cpp_lib_hardware_interference_size 201703L
> > +  inline constexpr size_t hardware_destructive_interference_size =
> > __GCC_DESTRUCTIVE_SIZE;
> > +  inline constexpr size_t hardware_constructive_interference_size =
> > __GCC_CONSTRUCTIVE_SIZE;
> > +#endif // __GCC_DESTRUCTIVE_SIZE
> > +}
> >  #endif // C++17
> >
> >  #if __cplusplus > 201703L

Putting aside my dislike of the entire feature, the libstdc++ parts
are fine, thanks.

  parent reply	other threads:[~2021-07-16 13:26 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20210716023656.670004-1-jason@redhat.com>
2021-07-16  2:41 ` Jason Merrill
2021-07-16  2:48   ` Noah Goldstein
2021-07-16 11:17     ` Jonathan Wakely
2021-07-16 13:27       ` Richard Earnshaw
2021-07-16 13:26   ` Jonathan Wakely [this message]
2021-07-16 15:12   ` Matthias Kretz
2021-07-16 15:30     ` Jason Merrill
2021-07-16 16:54       ` Jonathan Wakely
2021-07-16 18:43         ` Jason Merrill
2021-07-16 19:26         ` Matthias Kretz
2021-07-16 19:58           ` Jonathan Wakely
2021-07-17  8:14             ` Matthias Kretz
2021-07-17 13:32               ` Jonathan Wakely
2021-07-17 13:54                 ` Matthias Kretz
2021-07-17 21:37                   ` Jason Merrill
2021-07-19  9:41                     ` Richard Earnshaw
2021-07-20 16:43                       ` Jason Merrill
2021-07-20 18:05                 ` Thomas Rodgers
2021-07-16 17:20     ` Noah Goldstein
2021-07-16 19:37       ` Matthias Kretz
2021-07-16 21:23         ` Noah Goldstein

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAH6eHdSot60bjJTNWvXzHOLzNjasDpEK2TrXSM=csrN_==GZhg@mail.gmail.com' \
    --to=jwakely.gcc@gmail.com \
    --cc=Richard.Earnshaw@arm.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jason@redhat.com \
    --cc=libc-alpha@sourceware.org \
    --cc=libstdc++@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).