This adds the manipulators for use with basic_osyncstream. In order to
detect when an arbitrary basic_ostream is the base class of a
basic_syncbuf object, introduce a new intermediate base class
that stores the data members. The new base class stores a pointer and
two bools, which wastes (sizeof(vo
This encapsulates the storing and checking of the thread ID into a class
type, so that the macro _GLIBCXX_HAS_GTHREADS is only checked in one
place. The code doing the checks just calls member functions of the new
type, without caring whether that really does any work or not.
libstdc++-v3/ChangeLo
On 08/11/20 14:51 +0100, Paul Scharnofske via Libstdc++ wrote:
I think this would work:
jthread& operator=(jthread&& __x) noexcept
{
std::jthread(std::move(__x)).swap(*this);
return *this;
}
That looks a lot better than what I did, it's also consistent with other
places like std:
On 11/11/20 12:34 +, Jonathan Yong via Libstdc++ wrote:
cygwin/mingw hosted linker may support multiple targets with ELF relro
support. This breaks configure testing.
Attached patch excludes cygwin/mingw PE format from relro linker flag.
Patch OK?
OK, thanks.
From a72f02aec065c312528e4
On 11/11/20 12:41 +, Jonathan Wakely wrote:
On 11/11/20 12:34 +, Jonathan Yong via Libstdc++ wrote:
cygwin/mingw hosted linker may support multiple targets with ELF
relro support. This breaks configure testing.
Attached patch excludes cygwin/mingw PE format from relro linker
flag. Pat
This makes it possible to use std::thread in single-threaded builds.
All member functions are available, but attempting to create a new
thread will throw an exception.
The main benefit for most targets is that other headers such as
do not need to include the whole of just to be able to create a
Since glibc 2.27 the pthread_self symbol has been defined in libc rather
than libpthread. Because we only call pthread_self through a weak alias
it's possible for statically linked executables to end up without a
definition of pthread_self. This crashes when trying to call an
undefined weak symbol.
On 11/11/20 16:13 +, Jonathan Wakely wrote:
This makes it possible to use std::thread in single-threaded builds.
All member functions are available, but attempting to create a new
thread will throw an exception.
The main benefit for most targets is that other headers such as
do not need to
On 11/11/20 19:08 +0100, Jakub Jelinek via Libstdc++ wrote:
On Wed, Nov 11, 2020 at 05:24:42PM +, Jonathan Wakely wrote:
--- a/libgcc/gthr-posix.h
+++ b/libgcc/gthr-posix.h
@@ -684,7 +684,14 @@ __gthread_equal (__gthread_t __t1, __gthread_t __t2)
static inline __gthread_t
__gthread_self (v
This adds support for the new __ieee128 long double format on
powerpc64le targets.
Most of the complexity comes from wanting a single libstdc++.so library
that contains the symbols needed by code compiled with both
-mabi=ibmlongdouble and -mabi=ieeelongdouble (and not forgetting
-mlong-double-64 a
On 08/05/20 21:03 +0200, Matthias Kretz wrote:
Here's my last update to the std::experimental::simd patch. It's currently
based on the gcc-10 branch.
+
+// __next_power_of_2{{{
+/**
+ * \internal
We use @foo for Doxygen commens rather than \foo
+ * Returns the next power of 2 larger than
The expression used to calculate the maximum value for an integer type
assumes that the number of bits in the value representation is always
sizeof(T) * CHAR_BIT. This is not true for the __int20 type on msp430,
which has only 20 bits in the value representation but 32 bits in the
object representa
Here's a small tweak to __numeric_traits that I decided to do after
the previous patch.
Tested on powerpc64le-linux. Committed to trunk.
commit d21776ef90361e66401cd99c8ff0d98b46d3b0d6
Author: Jonathan Wakely
Date: Thu Nov 12 13:31:02 2020
libstdc++: Simplify __numeric_traits definition
On 11/11/20 17:31 +, Jonathan Wakely wrote:
On 11/11/20 16:13 +, Jonathan Wakely wrote:
This makes it possible to use std::thread in single-threaded builds.
All member functions are available, but attempting to create a new
thread will throw an exception.
The main benefit for most targe
On 04/11/20 10:55 -0800, Thomas Rodgers wrote:
--- a/libstdc++-v3/include/bits/atomic_base.h
+++ b/libstdc++-v3/include/bits/atomic_base.h
@@ -603,13 +603,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
#if __cplusplus > 201703L
+ template
+ _GLIBCXX_ALWAYS_INLINE void
+ _M_wait(_
On 11/11/20 19:08 +0100, Jakub Jelinek via Libstdc++ wrote:
On Wed, Nov 11, 2020 at 05:24:42PM +, Jonathan Wakely wrote:
--- a/libgcc/gthr-posix.h
+++ b/libgcc/gthr-posix.h
@@ -684,7 +684,14 @@ __gthread_equal (__gthread_t __t1, __gthread_t __t2)
static inline __gthread_t
__gthread_self (v
On 29/05/20 07:17 +0100, Mike Crowe via Libstdc++ wrote:
The futex system call supports waiting for an absolute time if
FUTEX_WAIT_BITSET is used rather than FUTEX_WAIT. Doing so provides two
benefits:
1. The call to gettimeofday is not required in order to calculate a
relative timeout.
2. I
To poll a std::future to see if it's ready you have to call one of the
timed waiting functions. The most obvious way is wait_for(0s) but this
was previously very inefficient because it would turn the relative
timeout to an absolute one by calling system_clock::now(). When the
relative timeout is ze
On 12/11/20 23:49 +, Jonathan Wakely wrote:
To poll a std::future to see if it's ready you have to call one of the
timed waiting functions. The most obvious way is wait_for(0s) but this
was previously very inefficient because it would turn the relative
timeout to an absolute one by calling sy
Currently this is shown when building libstdc++ on Solaris:
-lrt: open: No such file or directory
The error comes from the make_sunver.pl script which tries to open each
of its arguments. The arguments are passed by this make rule:
perl ${glibcxx_srcdir}/scripts/make_exports.pl \
On 13/11/20 11:07 +, Jonathan Wakely wrote:
Currently this is shown when building libstdc++ on Solaris:
-lrt: open: No such file or directory
The error comes from the make_sunver.pl script which tries to open each
of its arguments. The arguments are passed by this make rule:
perl $
On 13/11/20 11:02 +, Jonathan Wakely wrote:
On 12/11/20 23:49 +, Jonathan Wakely wrote:
To poll a std::future to see if it's ready you have to call one of the
timed waiting functions. The most obvious way is wait_for(0s) but this
was previously very inefficient because it would turn the
>Backporting the change to gcc-10 revealed an overflow bug in the
>existing code, resulting in blocking for years when given an absolute
>timeout in the distant past. There's still a similar bug in the new
>code (using futexes with absolute timeouts against clocks) where a
>large chrono::seconds va
On 13/11/20 20:29 +, Mike Crowe via Libstdc++ wrote:
On Friday 13 November 2020 at 17:25:22 +, Jonathan Wakely wrote:
+ // Return the relative duration from (now_s + now_ns) to (abs_s + abs_ns)
+ // as a timespec.
+ struct timespec
+ relative_timespec(chrono::seconds abs_s, chrono::n
On 13/11/20 21:12 +, Jonathan Wakely wrote:
On 13/11/20 20:29 +, Mike Crowe via Libstdc++ wrote:
On Friday 13 November 2020 at 17:25:22 +, Jonathan Wakely wrote:
+ // Return the relative duration from (now_s + now_ns) to (abs_s + abs_ns)
+ // as a timespec.
+ struct timespec
+ r
>> "Jakub" == Jakub Jelinek via Gcc-patches
>> writes:
>
>Jakub> * c-cppbuiltin.c: Include configargs.h.
>Jakub> (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is
>not
>Jakub> defined, predefine __STDCPP_THREADS__ to 1 unless thread_model
>is
>Jakub>
On 13/11/20 21:58 +, Mike Crowe via Libstdc++ wrote:
On Thursday 12 November 2020 at 23:07:47 +, Jonathan Wakely wrote:
On 29/05/20 07:17 +0100, Mike Crowe via Libstdc++ wrote:
> The futex system call supports waiting for an absolute time if
> FUTEX_WAIT_BITSET is used rather than FUTEX_
On 13/11/20 21:12 +, Jonathan Wakely wrote:
On 13/11/20 20:29 +, Mike Crowe via Libstdc++ wrote:
On Friday 13 November 2020 at 17:25:22 +, Jonathan Wakely wrote:
+ // Return the relative duration from (now_s + now_ns) to (abs_s + abs_ns)
+ // as a timespec.
+ struct timespec
+ r
On 13/11/20 22:46 +0100, Jakub Jelinek wrote:
On Fri, Nov 13, 2020 at 04:39:25PM -0500, Jason Merrill wrote:
On 11/13/20 2:20 PM, Tom Tromey wrote:
> > > > > > "Jakub" == Jakub Jelinek via Gcc-patches
writes:
>
> Jakub> 2020-11-13 Jakub Jelinek
>
> Jakub> * c-cppbuiltin.c: Include configar
On 13/11/20 22:45 +, Jonathan Wakely wrote:
On 13/11/20 21:12 +, Jonathan Wakely wrote:
On 13/11/20 20:29 +, Mike Crowe via Libstdc++ wrote:
On Friday 13 November 2020 at 17:25:22 +, Jonathan Wakely wrote:
+ // Return the relative duration from (now_s + now_ns) to (abs_s + abs
On 32-bit targets where userspace has switched to 64-bit time_t, we
cannot pass struct timespec to SYS_futex or SYS_clock_gettime, because
the userspace definition of struct timespec will not match what the
kernel expects.
We use the existence of the SYS_futex_time64 or SYS_clock_gettime_time64
ma
On Sat, 14 Nov 2020, 13:30 Mike Crowe via Libstdc++,
wrote:
> On Saturday 14 November 2020 at 00:17:59 +, Jonathan Wakely via
> Libstdc++ wrote:
> > On 32-bit targets where userspace has switched to 64-bit time_t, we
> > cannot pass struct timespec to SYS_futex or SYS_clock_gettime, because
>
On 16/11/20 11:23 +0100, Rainer Orth wrote:
Hi Jonathan,
But in practice the snippet above is only used if you explicitly
configure with --enable-libstdcxx-time={yes,rt} and will only add
anything to GLIBCXX_LIBS if clock_gettime or nanosleep lives in one of
librt or libposix4. I think libposix
On 16/11/20 11:17 +0100, Rainer Orth wrote:
Hi Jonathan,
Currently this is shown when building libstdc++ on Solaris:
-lrt: open: No such file or directory
The error comes from the make_sunver.pl script which tries to open each
of its arguments. The arguments are passed by this make rule:
On 16/11/20 10:32 +, Jonathan Wakely wrote:
On 16/11/20 11:17 +0100, Rainer Orth wrote:
Hi Jonathan,
Currently this is shown when building libstdc++ on Solaris:
-lrt: open: No such file or directory
The error comes from the make_sunver.pl script which tries to open each
of its arguments.
On 16/11/20 12:46 +0100, Rainer Orth wrote:
Hi Jonathan,
libstdc++-v3/ChangeLog:
* src/Makefile.am (libstdc++-symbols.ver-sun): Remove -lrt from
arguments passed to make_sunver.pl script.
* src/Makefile.in: Regenerate.
Tested sparc-solaris2.11. Rainer, does this look O
On 16/11/20 09:23 -0700, Tom Tromey wrote:
Jakub> If it is done in the library, it will be defined only if any of the
library
Jakub> headers are included.
Jakub> The https://eel.is/c++draft/cpp.predefined wording doesn't look like it
Jakub> would allow defining it only if certain headers are inc
Clang's "unsigned integer overflow" sanitizer can't tell the difference
between expected unsigned wraparound and a bug, and its developers tell
users to report bugs against libstdc++.
This disables the sanitizer where we are intentionally relying on
wraparound working as defined by the standard.
On Wed, 1 Sept 2021 at 02:44, Jonathan Yong <10wa...@gmail.com> wrote:
>
> On 8/31/21 9:02 AM, Jonathan Wakely wrote:
> > It looks like my questions about this patch never got an answer, and
> > it never got applied.
> >
> > Could somebody say whether TLS is enabled for native *-*-mingw*
> > builds
We already supported this feature as std::__invoke, for internal use.
This just adds a public version of it to .
Internal uses should continue to include and use
std::__invoke so that they don't need to include all of .
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/
P0418R2 removed some preconditions from std::atomic::compare_exchange_*
but we still enforce them via __glibcxx_assert. This removes those
assertions.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR c++/102177
* include/bits/atomic_base.h (__is_valid_cmpexch_failure_or
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/std/atomic: Tweak whitespace.
Tested x86_64-linux. Committed to trunk.
commit 892400f1f21ccee98dddcd90677038ce266248c8
Author: Jonathan Wakely
Date: Thu Sep 2 16:08:25 2021
libstdc++: Tweak whitespace in
For some reason r170217 didn't add compare_exchange_weak to the
__atomic_base partial specialization, and so weak compare exchange
operations on pointers use compare_exchange_strong instead.
This adds __atomic_base::compare_exchange_weak and then uses it in
std::atomic::compare_exchange_weak.
Sig
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/atomic_wait.h (_GLIBCXX_HAVE_PLATFORM_WAIT):
Define before first attempt to check it.
Tested x86_64-linux and powerpc64-linux, not committed yet.
I think we need this, otherwise __platform_wait_uses_type is f
On Thu, 2 Sept 2021 at 19:00, Jonathan Wakely wrote:
>
> * include/bits/atomic_wait.h (_GLIBCXX_HAVE_PLATFORM_WAIT):
> Define before first attempt to check it.
>
> Tested x86_64-linux and powerpc64-linux, not committed yet.
Actually ignore that ... I tested the wrong patch. This on
Ping (and remember to CC a maintainer this time).
On 31/08/21 09:53 +0100, Jonathan Wakely wrote:
The description of behaviour is incorrect, the virtual base gets
assigned before entering the bodies of A::operator= and B::operator=,
not after.
The example is also ill-formed (passing a string l
This avoids test.invalid.some.domain being successfully resolved.
libstdc++-v3/ChangeLog:
* testsuite/experimental/net/internet/resolver/ops/lookup.cc:
Fix invalid hostname to only match the .invalid TLD.
Tested x86_64-linux. Committed to trunk.
commit 7f8af6dc82a0dac0d97fdd4d1f
Please CC libstdc++ patches to the libstdc++ list, or they won't get
reviewed (because I don't subscribe to gcc-patches).
GCC 5 does implement SSO but it's only used conditionally. Your patch
uses numeric_limits unconditionally, which will result in
over-allocation for COW strings.
There also see
On Wed, 1 Sept 2021 at 10:52, Jonathan Wakely wrote:
>
> On Wed, 1 Sept 2021 at 02:44, Jonathan Yong <10wa...@gmail.com> wrote:
> >
> > On 8/31/21 9:02 AM, Jonathan Wakely wrote:
> > > It looks like my questions about this patch never got an answer, and
> > > it never got applied.
> > >
> > > Coul
N.B. Please CC *both* the libstdc++ list and the gcc-patches list, as
per https://gcc.gnu.org/lists.html
On Wed, 15 Sept 2021 at 14:02, 刘可 wrote:
>
> Thank you for your review, and I apologize for my mistake. I have updated and
> tested it!
Hmm, it doesn't work though. How did you test it?
For
The https://gcc.gnu.org/git.html page is a total mess, listing dozens
and dozens of branches which haven't seen updates in a decade and
which are under the refs/dead/heads/* are of the Git repo.
This moves them all to the "Inactive" or "Merged" section, as
appropriate.
OK for wwwdocs?
commit cb
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/unique_ptr.h (__uniq_ptr_impl::_M_ptr)
(__uniq_ptr_impl::_M_deleter): Add noexcept.
Tested powerpc64le-linux. Committed to trunk.
commit 869107c9c9752c9a53cdb06179c1e6be6d2e5f44
Author: Jonathan Wakely
Date:
When the values is guaranteed to fit in the SSO buffer we know the
string won't allocate, so the function can be noexcept. For 32-bit
integers, we know they need no more than 9 bytes (or 10 with a minus
sign) and the SSO buffer is 15 bytes.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* src/c++98/Makefile.am: Use CXXCOMPILE not LTCXXCOMPILE.
* src/c++98/Makefile.in: Regenerate.
Tested x86_64-linux. Committed to trunk.
commit 2c351dafcbc871c088ce09ae69bc08871f7df57b
Author: Jonathan Wakely
Date: Wed Se
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102280
* include/std/span (span(Range&&)): Add constraint to deduction
guide.
Tested x86_64-linux. Committed to trunk.
commit e67917f5df9d84f5aed3513b3931a82870d25135
Author: Jonathan Wakely
Date: We
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102270
* include/std/tuple (_Head_base, _Tuple_impl): Add
_GLIBCXX20_CONSTEXPR to allocator-extended constructors.
(tuple<>::swap(tuple&)): Add _GLIBCXX20_CONSTEXPR.
* testsuite/20_util/tu
This was just a copy and paste error.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/fs_path.h (advance): Remove non-deducible
template parameter.
Tested x86_64-linux. Committed to trunk.
commit 21c760510d31253074577a14021fdc6ad44084b6
Author: Jonathan W
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/std/optional (nullptr_t): Make constructor noexcept.
Tested x86_64-linux. Committed to trunk.
commit cbe705a2f749c98a5f803afeb207e175b4c9a3c3
Author: Jonathan Wakely
Date: Thu Sep 16 14:14:38 2021
libstdc++: Add n
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* doc/xml/manual/using.xml: Generalize to apply to more than
just -std=c++11.
* doc/html/manual/using_macros.html: Regenerate.
Committed to trunk.
commit bd0df30a7bc7a2e98e643cf84901e5383f83c005
Author: Jonathan Wak
Compiling these tests still times out too often when running the
testsuite with more parallel jobs than there are available cores.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* testsuite/ext/pb_ds/regression/tree_map_rand.cc: Increase
timeout factor to 3.
* te
When the build configuration changes and Makefiles are recreated, the
src/debug/Makefile and src/debug/*/Makefile files are not recreated,
because they're not managed in the usual way by automake. This can lead
to build failures or surprising inconsistencies between the main and
debug versions of t
On Thu, 16 Sep 2021, 23:24 Thomas Rodgers,
wrote:
> From: Thomas Rodgers
>
> Remove UB in atomic_ref/wait_notify test.
>
> Signed-off-by: Thomas Rodgers
>
> libstdc++-v3/ChangeLog:
>
> PR libstdc++/101761
> * testsuite/29_atomics/atomic_ref/wait_notify.cc (test): Use
> v
On 16/09/21 23:07 +0100, Jonathan Wakely wrote:
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102270
* include/std/tuple (_Head_base, _Tuple_impl): Add
_GLIBCXX20_CONSTEXPR to allocator-extended constructors.
(tuple<>::swap(tuple&)): Add _G
The list of architectures that support the option is incomplete.
gcc/ChangeLog:
* configure.ac: Fix --with-multilib-list description.
* configure: Regenerate.
OK for trunk?
commit 630dc3085cbd87a224129177870103e2c4fbf22a
Author: Jonathan Wakely
Date: Fri Sep 17 12:34:22 2021
The libstdc++ testsuite only runs .cc files, so these two old tests have
never been run.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* testsuite/26_numerics/valarray/dr630-3.C: Moved to...
* testsuite/26_numerics/valarray/dr630-3.cc: ...here.
* testsuite/27_io
On Fri, 17 Sept 2021 at 13:08, Richard Biener
wrote:
>
> On Fri, Sep 17, 2021 at 1:17 PM Thomas Schwinge
> wrote:
> >
> > Hi!
> >
> > On 2021-09-10T10:00:25+0200, I wrote:
> > > On 2021-09-01T19:31:19-0600, Martin Sebor via Gcc-patches
> > > wrote:
> > >> On 8/30/21 4:46 AM, Thomas Schwinge wr
On Fri, 17 Sep 2021, 16:52 Thomas Schwinge, wrote:
> Hi!
>
> On 2021-09-17T15:03:18+0200, Richard Biener
> wrote:
> > On Fri, Sep 17, 2021 at 2:39 PM Jonathan Wakely
> wrote:
> >> On Fri, 17 Sept 2021 at 13:08, Richard Biener
> >> wrote:
> >> > On Fri, Sep 17, 2021 at 1:17 PM Thomas Schwinge <
Also rename the test so it actually runs.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102270
* include/std/tuple (_Tuple_impl): Add constexpr to constructor
missed in previous patch.
* testsuite/20_util/tuple/cons/102270.C: Moved to...
On 17/09/21 12:25 +0100, Jonathan Wakely wrote:
On 16/09/21 23:07 +0100, Jonathan Wakely wrote:
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102270
* include/std/tuple (_Head_base, _Tuple_impl): Add
_GLIBCXX20_CONSTEXPR to allocator-extended cons
All path::iterator operations are non-throwing.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/fs_path.h (path::iterator): Add noexcept to all
member functions and friend functions.
(distance): Add noexcept.
(advance): Add noexcept and inli
On 17/09/21 20:47 +0100, Jonathan Wakely wrote:
On 17/09/21 12:25 +0100, Jonathan Wakely wrote:
On 16/09/21 23:07 +0100, Jonathan Wakely wrote:
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102270
* include/std/tuple (_Head_base, _Tuple_impl): Add
On Wed, 22 Sept 2021 at 18:09, Antony Polukhin wrote:
>
> std::unique_ptr allows construction from std::unique_ptr of derived
> type as per [unique.ptr.single.asgn] and [unique.ptr.single.ctor]. If
> std::default_delete is used with std::unique_ptr, then after such
> construction a delete is called
On Wed, 22 Sept 2021 at 18:56, Antony Polukhin wrote:
>
> ср, 22 сент. 2021 г. в 20:44, Jonathan Wakely :
> >
> > On Wed, 22 Sept 2021 at 18:09, Antony Polukhin wrote:
> > >
> > > std::unique_ptr allows construction from std::unique_ptr of derived
> > > type as per [unique.ptr.single.asgn] and [un
On 16/09/21 15:41 +0100, Jonathan Wakely wrote:
The https://gcc.gnu.org/git.html page is a total mess, listing dozens
and dozens of branches which haven't seen updates in a decade and
which are under the refs/dead/heads/* are of the Git repo.
This moves them all to the "Inactive" or "Merged" sec
On Wed, 22 Sept 2021 at 23:19, Jim Wilson wrote:
> On Fri, Sep 17, 2021 at 4:39 AM Jonathan Wakely via Gcc-patches <
> gcc-patches@gcc.gnu.org> wrote:
>
>> The list of architectures that support the option is incomplete.
>>
>> gcc/ChangeLog:
>>
>>
On Thu, 23 Sept 2021 at 11:36, Jonathan Wakely wrote:
> On Wed, 22 Sept 2021 at 23:19, Jim Wilson wrote:
>
>> On Fri, Sep 17, 2021 at 4:39 AM Jonathan Wakely via Gcc-patches <
>> gcc-patches@gcc.gnu.org> wrote:
>>
>>> The list of architectures that suppor
Although 0 is not an errno value, it should still be recognized as
corresponding to a value belonging to the generic_category().
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102425
* src/c++11/system_error.cc
(system_error_category::default_error_c
Although 0 is not an errno value, it should still be recognized as
corresponding to a value belonging to the generic_category().
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102425
* src/c++11/system_error.cc
(system_error_category::default_error_c
This ensures that the objects returned by std::generic_category() and
std::system_category() are initialized before any code starts executing,
and are not destroyed at the end of the program. This means it is always
safe to access them, even during startup and termination. See LWG 2992
and P1195R0
The std::system_category error category should be used for
system-specific error codes, which means on Windows it should be used
for Windows error codes. Currently that category assumes that the error
numbers it deals with are errno numbers, which means that
ERROR_ACCESS_DENIED (which has value 0x
This test tries to ensure that can be included after
defining _XOPEN_SOURCE=600, which doesn't test anything if that header
is already included via the PCH before the macro
definition. Disable PCH so that it behaves as intended.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
*
I added extra dg-error directives for C++20 to match the extra errors
caused by some of the call stack being constexpr in C++20. Since Jason's
changes to reduce those errors, those dg-error lines no longer match.
This removes them again.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
On Thu, 23 Sep 2021, 20:07 Jakub Jelinek via Libstdc++, <
libstd...@gcc.gnu.org> wrote:
> On Thu, Sep 23, 2021 at 11:08:37AM -0700, Thomas Rodgers wrote:
> > From: Thomas Rodgers
> >
> > This change implements P0528 which requires that padding bits not
> > participate in atomic compare exchange o
These functions are constexpr, which means they are implicitly inline.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/range_access.h (cbegin, cend): Remove redundant
'inline' specifier.
Tested x86_64-linux. Committed to trunk.
commit 9b11107ed72ca543af41
On Mon, 27 Sept 2021 at 21:26, François Dumont via Libstdc++
wrote:
>
> Here is a small patch to fix a test which fails in
> _GLIBCXX_VERSION_NAMESPACE mode.
>
> IMHO it would be better to avoid putting content in
> versioned namespace, no ?
>
> There is of course more work to do, so for now here
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
PR libstdc++/102499
* include/bits/fs_path.h (path::begin, path::end): Add noexcept
to declarations, to match definitions.
Tested x86_64-linux. Committed to trunk.
commit f2b7f56a15d9cbbd2f0db22e0e39c4dd161bab69
Aut
The previous message told you something was wrong, but not why it
happened or why it's bad. This changes it to explain that the function
is being misused.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/move.h (forward(remove_reference_t&&)):
Improve text o
This allows std::__to_address to be used with __normal_iterator in
C++11/14/17 modes. Without the partial specialization the deduced
pointer_traits::element_type is incorrect, and so the return type of
__to_address is wrong.
A similar partial specialization is probably needed for
__gnu_debug::_Saf
The _OutputIteratorConcept should be checked using the correct value
category. The std::move_backward and std::copy_backward algorithms
should use _OutputIteratorConcept instead of _ConvertibleConcept.
In order to use the correct value category, the concept should use a
function that returns _Valu
Types used in ordered containers need to be comparable, or the container
needs to use a custom comparison function. These tests fail when
_GLIBCXX_CONCEPT_CHECKS is defined, because the element types aren't
comparable.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* testsuite/2
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* testsuite/25_algorithms/copy/34595.cc: Add missing operation
for type used as an iterator.
* testsuite/25_algorithms/unique_copy/check_type.cc: Likewise.
Tested x86_64-linux. Committed to trunk.
commit 5f1db7627f6
This adds some additional checks the the C++98-style concept checks for
iterators, and removes some bogus checks for mutable iterators. Instead
of requiring that the result of dereferencing a mutable iterator is
assignable (which is a property of the value type, not required for the
iterator) check
The extension that allows implicitly rebinding a container's allocator
is not allowed when _GLIBCXX_CONCEPT_CHECKS is defined, so skip the
tests for that extension.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
*
testsuite/23_containers/deque/requirements/explicit_instantiatio
As an extension, our container adaptors SFINAE away the default
constructor if the adapted sequence container is not default
constructible. When _GLIBCXX_CONCEPT_CHECKS is defined we enforce that
the sequence is default constructible, so the tests for the extension
fail. This disables the relevant
On Thu, 2 Sept 2021 at 22:25, Jonathan Wakely wrote:
>
> On Thu, 2 Sept 2021 at 19:00, Jonathan Wakely wrote:
> >
> > * include/bits/atomic_wait.h (_GLIBCXX_HAVE_PLATFORM_WAIT):
> > Define before first attempt to check it.
> >
> > Tested x86_64-linux and powerpc64-linux, not committ
This fixes a logic error in the futex-based timed wait.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/atomic_timed_wait.h (__platform_wait_until_impl):
Return false for ETIMEDOUT and true otherwise.
Tested x86_64-linux.
I'm not seeing any tests fail as
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/regex.h (basic_regex, swap): Add noexcept to
non-throwing functions.
* include/bits/regex_automaton.h (_State_base, _State)
(_NFA_base): Likewise.
* include/bits/regex_compiler.h (_Compi
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/regex_compiler.tcc: Add line break in empty while
statement.
* include/bits/regex_executor.tcc: Avoid unused parameter
warning.
Tested x86_64-linux. Committed to trunk.
commit b5f276b8c76d892f
There is no benefit to using _SizeT instead of size_t, and IterT tells
you less about the type than const _CharT*. This removes some unhelpful
typedefs.
Signed-off-by: Jonathan Wakely
libstdc++-v3/ChangeLog:
* include/bits/regex_automaton.h (_NFA_base::_SizeT): Remove.
* include
On Tue, 28 Sept 2021 at 21:21, François Dumont via Libstdc++
wrote:
>
> On 27/09/21 11:06 pm, Jonathan Wakely wrote:
> > On Mon, 27 Sept 2021 at 21:26, François Dumont via Libstdc++
> > wrote:
> >> Here is a small patch to fix a test which fails in
> >> _GLIBCXX_VERSION_NAMESPACE mode.
> >>
> >>
1401 - 1500 of 3694 matches
Mail list logo