This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: std::forward_list optim for always equal allocator
- From: Jonathan Wakely <jwakely at redhat dot com>
- To: François Dumont <frs dot dumont at gmail dot com>
- Cc: "libstdc++ at gcc dot gnu dot org" <libstdc++ at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 8 Sep 2017 17:19:40 +0100
- Subject: Re: std::forward_list optim for always equal allocator
- Authentication-results: sourceware.org; auth=none
- Authentication-results: ext-mx04.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com
- Authentication-results: ext-mx04.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=jwakely at redhat dot com
- Dmarc-filter: OpenDMARC Filter v1.3.2 mx1.redhat.com EAC798008B
- References: <c199ddfe-3292-f42e-a2ce-aa3ef92e5910@gmail.com> <f8941efc-9020-c64e-f31a-d4ca483f74a3@gmail.com>
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 so do I need to restore it ?
I eventually restore the _M_head() in _Fwd_list_impl constructors
cause IMO it is the inline init of _M_next in _Fwd_list_node_base
which should be removed. But I remember Jonathan that you didn't want
to do so because gcc was not good enough in detecting usage of
uninitialized variables, is it still true ?
Why should it be removed?