Re: Implement C++20 constexpr , , and

2019-03-29 Thread Jonathan Wakely
On 29/03/19 12:02 -0400, Ed Smith-Rowland wrote: On 3/29/19 9:23 AM, Jakub Jelinek wrote: On Fri, Mar 29, 2019 at 09:10:26AM -0400, Ed Smith-Rowland via gcc-patches wrote: Greetings, This patch implements C++20 constexpr for , , . It's a large patch but only affects C++20 and the volume is m

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Daniel Krügler
Am Fr., 29. März 2019 um 19:08 Uhr schrieb Ed Smith-Rowland via libstdc++ : > > I made __memmove and __memcmp inline so that, certainly for C++ < 20 > these don't pessimize. Hmmh, are you sure? In my (not very up-to-date) code base I find that c++config.h defines #ifndef _GLIBCXX20_CONSTEXPR # if

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Ed Smith-Rowland via gcc-patches
On 3/29/19 12:39 PM, Jakub Jelinek wrote: On Fri, Mar 29, 2019 at 12:02:48PM -0400, Ed Smith-Rowland wrote: This differs from the previous patch in actually testing constexpr :-\ and in the addition of wrappers for __builtin_memmove and __builtin_memcmp that supply constexpr branches if C++20 an

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Jakub Jelinek
On Fri, Mar 29, 2019 at 12:02:48PM -0400, Ed Smith-Rowland wrote: > > > This differs from the previous patch in actually testing constexpr :-\ and > > > in the addition of wrappers for __builtin_memmove and __builtin_memcmp > > > that > > > supply constexpr branches if C++20 and is_constant_evalua

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Jakub Jelinek
On Fri, Mar 29, 2019 at 12:30:02PM -0400, Ed Smith-Rowland wrote: > I see what you did there ;-) I could make my patch use the same idiom as > what you have in the char_traits patch if folks would prefer. > > BTW, what does > > (void) __s; Avoid -Wunused-parameter warning. Jakub

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Ed Smith-Rowland via gcc-patches
On 3/29/19 11:12 AM, Jakub Jelinek wrote: On Fri, Mar 29, 2019 at 11:07:53AM -0400, Jason Merrill wrote: On Tue, Mar 19, 2019 at 4:57 PM Ed Smith-Rowland via gcc-patches wrote: On 3/18/19 6:18 PM, Jonathan Wakely wrote: On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: I'm very s

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Ed Smith-Rowland via gcc-patches
On 3/29/19 9:23 AM, Jakub Jelinek wrote: On Fri, Mar 29, 2019 at 09:10:26AM -0400, Ed Smith-Rowland via gcc-patches wrote: Greetings, This patch implements C++20 constexpr for , , . It's a large patch but only affects C++20 and the volume is mostly test cases. This differs from the previous

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Jakub Jelinek
On Fri, Mar 29, 2019 at 11:07:53AM -0400, Jason Merrill wrote: > On Tue, Mar 19, 2019 at 4:57 PM Ed Smith-Rowland via gcc-patches > wrote: > > > > On 3/18/19 6:18 PM, Jonathan Wakely wrote: > > > On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: > > > I'm very surprised that none of t

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Jason Merrill
On Tue, Mar 19, 2019 at 4:57 PM Ed Smith-Rowland via gcc-patches wrote: > > On 3/18/19 6:18 PM, Jonathan Wakely wrote: > > On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: > > I'm very surprised that none of the algos that dispatch to > > __builtin_memove need changes, because those

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Jakub Jelinek
On Fri, Mar 29, 2019 at 09:10:26AM -0400, Ed Smith-Rowland via gcc-patches wrote: > Greetings, > > This patch implements C++20 constexpr for , , . > > It's a large patch but only affects C++20 and the volume is mostly test > cases. > > This differs from the previous patch in actually testing co

Re: Implement C++20 constexpr , , and

2019-03-29 Thread Ed Smith-Rowland via gcc-patches
Greetings, This patch implements C++20 constexpr for , , . It's a large patch but only affects C++20 and the volume is mostly test cases. This differs from the previous patch in actually testing constexpr :-\ and in the addition of wrappers for __builtin_memmove and __builtin_memcmp that su

Re: Implement C++20 constexpr , , and

2019-03-19 Thread Ed Smith-Rowland via gcc-patches
On 3/19/19 4:57 PM, Ed Smith-Rowland via libstdc++ wrote: On 3/18/19 6:18 PM, Jonathan Wakely wrote: On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: Greetings, This patch implements C++20 p0202 - Add Constexpr Modifiers to Functions in and Headers and C++20 p1023 - constexp

Re: Implement C++20 constexpr , , and

2019-03-19 Thread Ed Smith-Rowland via gcc-patches
On 3/18/19 6:18 PM, Jonathan Wakely wrote: On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: Greetings, This patch implements C++20 p0202 - Add Constexpr Modifiers to Functions in and Headers and C++20 p1023 - constexpr comparison operators for std::array. The patch is large

Re: Implement C++20 constexpr , , and

2019-03-18 Thread Ed Smith-Rowland via gcc-patches
On 3/18/19 6:18 PM, Jonathan Wakely wrote: On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: Greetings, This patch implements C++20 p0202 - Add Constexpr Modifiers to Functions in and Headers and C++20 p1023 - constexpr comparison operators for std::array. The patch is large

Re: Implement C++20 constexpr , , and

2019-03-18 Thread Jonathan Wakely
On 17/03/19 22:54 -0400, Ed Smith-Rowland via libstdc++ wrote: Greetings, This patch implements C++20 p0202 - Add Constexpr Modifiers to Functions in and Headers and C++20 p1023 - constexpr comparison operators for std::array. The patch is large because of the testsuite additions. Basical

Implement C++20 constexpr , , and

2019-03-17 Thread Ed Smith-Rowland via gcc-patches
Greetings, This patch implements C++20 p0202 - Add Constexpr Modifiers to Functions in and Headers and C++20 p1023 - constexpr comparison operators for std::array. The patch is large because of the testsuite additions. Basically, the algorithms and the array comparison operators are all m