Re: std::forward_list optim for always equal allocator

2018-01-08 Thread Jonathan Wakely
On 23/11/17 22:22 +0100, François Dumont wrote: Gentle reminder for this patch. I looked when the constructor got unused and I think it is back in June 2015 in git commit: commit debb6aabb771ed02cb7256a7719555e5fbd7d3f7 Author: redi Date:   Wed Jun 17 17:45:45 2015 +     * include/b

Re: std::forward_list optim for always equal allocator

2017-11-23 Thread François Dumont
Gentle reminder for this patch. I looked when the constructor got unused and I think it is back in June 2015 in git commit: commit debb6aabb771ed02cb7256a7719555e5fbd7d3f7 Author: redi Date:   Wed Jun 17 17:45:45 2015 +     * include/bits/forward_list.h     (_Fwd_list_base(const

Re: std::forward_list optim for always equal allocator

2017-09-12 Thread François Dumont
On 12/09/2017 00:10, Jonathan Wakely wrote: On 11/09/17 22:39 +0200, Daniel Krügler wrote: 2017-09-11 22:36 GMT+02:00 François Dumont : [..] So my remark was rather for the: _Fwd_list_iterator() noexcept : _M_node() { } that could simply be _Fwd_list_iterator() = default; no

Re: std::forward_list optim for always equal allocator

2017-09-11 Thread Jonathan Wakely
On 11/09/17 22:39 +0200, Daniel Krügler wrote: 2017-09-11 22:36 GMT+02:00 François Dumont : [..] So my remark was rather for the: _Fwd_list_iterator() noexcept : _M_node() { } that could simply be _Fwd_list_iterator() = default; no ? Yes, that should be fine. I'm not sure

Re: std::forward_list optim for always equal allocator

2017-09-11 Thread Daniel Krügler
2017-09-11 22:36 GMT+02:00 François Dumont : [..] > So my remark was rather for the: > > _Fwd_list_iterator() noexcept > : _M_node() { } > > that could simply be > > _Fwd_list_iterator() = default; > > no ? Yes, that should be fine. - Daniel

Re: std::forward_list optim for always equal allocator

2017-09-11 Thread François Dumont
On 11/09/2017 14:11, Jonathan Wakely wrote: On 11/09/17 07:44 +0200, Daniel Krügler wrote: 2017-09-11 7:12 GMT+02:00 François Dumont : When user declare a container iterator like that: std::forward_list::iterator it; There is no reason to initialize it with a null node pointer. It is just an

Re: std::forward_list optim for always equal allocator

2017-09-11 Thread Jonathan Wakely
On 11/09/17 07:44 +0200, Daniel Krügler wrote: 2017-09-11 7:12 GMT+02:00 François Dumont : When user declare a container iterator like that: std::forward_list::iterator it; There is no reason to initialize it with a null node pointer. It is just an uninitialized iterator which is invalid to us

Re: std::forward_list optim for always equal allocator

2017-09-10 Thread Daniel Krügler
2017-09-11 7:12 GMT+02:00 François Dumont : > When user declare a container iterator like that: > > std::forward_list::iterator it; > > There is no reason to initialize it with a null node pointer. It is just an > uninitialized iterator which is invalid to use except to initialize it. While that i

Re: std::forward_list optim for always equal allocator

2017-09-10 Thread François Dumont
On 08/09/2017 18:19, Jonathan Wakely wrote: On 28/08/17 21:09 +0200, François Dumont wrote: Hi Any news for this patch ? It does remove a constructor: -_Fwd_list_impl(const _Node_alloc_type& __a) -: _Node_alloc_type(__a), _M_head() It was already unused before the pa

Re: std::forward_list optim for always equal allocator

2017-09-08 Thread Jonathan Wakely
On 28/08/17 21:09 +0200, François Dumont wrote: Hi Any news for this patch ? It does remove a constructor: -_Fwd_list_impl(const _Node_alloc_type& __a) -: _Node_alloc_type(__a), _M_head() It was already unused before the patch. Do you think it has ever been used and

Re: std::forward_list optim for always equal allocator

2017-08-28 Thread François Dumont
Hi Any news for this patch ? It does remove a constructor: -_Fwd_list_impl(const _Node_alloc_type& __a) -: _Node_alloc_type(__a), _M_head() It was already unused before the patch. Do you think it has ever been used and so do I need to restore it ? I eventuall

Re: std::forward_list optim for always equal allocator

2017-07-17 Thread Daniel Krügler
2017-07-17 22:10 GMT+02:00 François Dumont : > Hi > > Here is the patch to implement the always equal alloc optimization for > forward_list. With this version there is no abi issue. > > I also prefer to implement the _Fwd_list_node_base move operator for > consistency with the move construc