public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Biener <richard.guenther@gmail.com>
To: Jakub Jelinek <jakub@redhat.com>
Cc: "Joseph S. Myers" <joseph@codesourcery.com>,
	Hongtao Liu <crazylht@gmail.com>,
	 liuhongt <hongtao.liu@intel.com>,
	GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] Enable auto-vectorization at O2 with very-cheap cost model.
Date: Mon, 6 Sep 2021 14:43:40 +0200	[thread overview]
Message-ID: <CAFiYyc2PCPu1is4ySAeCqrV+XVuycOCMnMYS_yS_-9yKaNBKhg@mail.gmail.com> (raw)
In-Reply-To: <20210906123024.GX920497@tucnak>

On Mon, Sep 6, 2021 at 2:30 PM Jakub Jelinek <jakub@redhat.com> wrote:
>
> On Mon, Sep 06, 2021 at 02:18:59PM +0200, Richard Biener wrote:
> > On Mon, Sep 6, 2021 at 1:15 PM Jakub Jelinek <jakub@redhat.com> wrote:
> > >
> > > On Mon, Sep 06, 2021 at 07:15:41PM +0800, Hongtao Liu wrote:
> > > > > So what about finish_options then?
> > > > > default_options_optimization has only a single caller that then calls
> > > > > read_cmdline_options and then finish_options.
> > > > in finish_options
> > > > (gdb) p opts_set->x_flag_tree_loop_vectorize
> > > > $37 = 1
> > > > with -O2 -ftree-loop-vectorize,
> > > >
> > > > but
> > > > 1000   if (opts->x_dump_base_name
> > > > (gdb) p opts_set->x_flag_tree_loop_vectorize
> > > > $38 = 0
> > > > for -O2 -ftree-vectorize???
> > > >
> > > > Any magic  for ftree-vectorize w/ EnabledBy???
> > >
> > > I guess a way to get this working would be:
> > >  ; Alias to enable both -ftree-loop-vectorize and -ftree-slp-vectorize.
> > >  ftree-vectorize
> > > -Common Optimization
> > > +Common Var(flag_tree_vectorize) Optimization
> > >  Enable vectorization on trees.
> > >
> > > and then you can test both
> > > opts_set->x_flag_tree_vectorize
> > > and
> > > opts_set->x_flag_tree_loop_vectorize
> >
> > Or make EnabledBy have set opts_set-> as well.
>
> That would change a little bit what *_set->x_* means.
>
> If user has explicit -O2, we have *_set->x_optimize set,
> but don't enable it on all the suboptions that are implicitly
> enabled because explicit -O2 has been used.
> And isn't EnabledBy practically the same?  If user writes
> -Wall explicitly which implicitly enables hundreds of warning
> options, do we want just Wall or also all the other options
> marked as explicit?  E.g. backend code than can't easily differentiate
> between -Wwhatever and -Wall implying -Wwhatever and e.g. changing that
> if implicit only.

Hmm, good point.

Richard.

>
>         Jakub
>

  reply	other threads:[~2021-09-06 12:43 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-06  8:46 liuhongt
2021-09-06  8:55 ` Hongtao Liu
2021-09-06  9:18 ` Richard Biener
2021-09-06  9:41   ` Jakub Jelinek
2021-09-06 10:58     ` Hongtao Liu
2021-09-06 11:01       ` Jakub Jelinek
2021-09-06 11:15         ` Hongtao Liu
2021-09-06 11:15           ` Jakub Jelinek
2021-09-06 12:18             ` Richard Biener
2021-09-06 12:30               ` Jakub Jelinek
2021-09-06 12:43                 ` Richard Biener [this message]
2021-09-06 11:05     ` Richard Biener
2021-09-06  9:41   ` Hongtao Liu
2021-09-06 16:37 ` Joseph Myers
2021-09-07  2:07   ` Hongtao Liu
2021-09-16  4:33 liuhongt
2021-09-16  8:22 ` Richard Biener
2021-09-16  9:03   ` Hongtao Liu
2021-09-16 12:31     ` Richard Biener
2021-09-17  3:26       ` Hongtao Liu
2021-09-17  7:47         ` Richard Biener
2021-09-17  8:06           ` Hongtao Liu
2021-09-19 20:13     ` Martin Sebor
2021-09-22  1:38       ` Hongtao Liu
2021-09-22 14:21         ` Martin Sebor
2021-09-22 15:03           ` Martin Sebor
2021-09-23  1:48           ` Hongtao Liu
2021-09-23  2:08             ` Hongtao Liu
2021-09-23  6:30               ` Richard Biener
2021-09-23 15:18                 ` Martin Sebor
2021-09-24  3:32                   ` Hongtao Liu
2021-09-24 14:27                     ` Martin Sebor
2021-09-26  3:18                       ` liuhongt
2021-09-28 11:18                         ` Richard Biener
2021-10-07 15:34                         ` Martin Liška
2021-10-07 15:36                           ` H.J. Lu
2021-10-08  2:16                             ` Hongtao Liu
2021-10-08 10:49                 ` Aldy Hernandez
2021-10-08 23:43                   ` Martin Sebor

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=CAFiYyc2PCPu1is4ySAeCqrV+XVuycOCMnMYS_yS_-9yKaNBKhg@mail.gmail.com \
    --to=richard.guenther@gmail.com \
    --cc=crazylht@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=hongtao.liu@intel.com \
    --cc=jakub@redhat.com \
    --cc=joseph@codesourcery.com \
    /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).