public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely@redhat.com>
To: Richard Biener <rguenther@suse.de>
Cc: gcc-patches@gcc.gnu.org, Jakub Jelinek <jakub@redhat.com>
Subject: Re: [PATCH] add move CTOR to auto_vec, use auto_vec for get_loop_exit_edges
Date: Thu, 24 Sep 2020 14:16:26 +0100	[thread overview]
Message-ID: <20200924131626.GF6061@redhat.com> (raw)
In-Reply-To: <nycvar.YFH.7.76.2009241110520.10073@p653.nepu.fhfr.qr>

On 24/09/20 11:11 +0200, Richard Biener wrote:
>On Wed, 26 Aug 2020, Richard Biener wrote:
>
>> On Thu, 6 Aug 2020, Richard Biener wrote:
>>
>> > On Thu, 6 Aug 2020, Richard Biener wrote:
>> >
>> > > This adds a move CTOR to auto_vec<T, 0> and makes use of a
>> > > auto_vec<edge> return value for get_loop_exit_edges denoting
>> > > that lifetime management of the vector is handed to the caller.
>> > >
>> > > The move CTOR prompted the hash_table change because it appearantly
>> > > makes the copy CTOR implicitely deleted (good) and hash-table
>> > > expansion of the odr_enum_map which is
>> > > hash_map <nofree_string_hash, odr_enum> where odr_enum has an
>> > > auto_vec<odr_enum_val, 0> member triggers this.  Not sure if
>> > > there's a latent bug there before this (I think we're not
>> > > invoking DTORs, but we're invoking copy-CTORs).
>> > >
>> > > Bootstrap / regtest running on x86_64-unknown-linux-gnu.
>> > >
>> > > Does this all look sensible and is it a good change
>> > > (the get_loop_exit_edges one)?
>> >
>> > Regtest went OK, here's an update with a complete ChangeLog
>> > (how useful..) plus the move assign operator deleted, copy
>> > assign wouldn't work as auto-generated and at the moment
>> > there's no use of assigning.  I guess if we'd have functions
>> > that take an auto_vec<> argument meaning they will destroy
>> > the vector that will become useful and we can implement it.
>> >
>> > OK for trunk?
>>
>> Ping.
>
>Ping^2.

Looks good to me as far as the use of C++ features goes.


  reply	other threads:[~2020-09-24 13:16 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-06 12:58 Richard Biener
2020-08-06 14:15 ` Richard Biener
2020-08-26 12:33   ` Richard Biener
2020-09-24  9:11     ` Richard Biener
2020-09-24 13:16       ` Jonathan Wakely [this message]
2020-09-24 15:05         ` Richard Biener
2020-09-25 11:40           ` Tom de Vries

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=20200924131626.GF6061@redhat.com \
    --to=jwakely@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jakub@redhat.com \
    --cc=rguenther@suse.de \
    /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).