This is the mail archive of the
mailing list for the GCC project.
Re: tree if convert pass control
- From: Richard Biener <richard dot guenther at gmail dot com>
- To: Xinliang David Li <davidxl at google dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 16 Sep 2013 11:04:31 +0200
- Subject: Re: tree if convert pass control
- Authentication-results: sourceware.org; auth=none
- References: <CAAkRFZL=gmygiRtf7YZWyZdi8-FOrVZJQfyC_=RpuK3W=ZxMtA at mail dot gmail dot com>
On Sat, Sep 14, 2013 at 8:10 AM, Xinliang David Li <firstname.lastname@example.org> wrote:
> tree if conversion is an enabler pass for vectorization, so by
> default, it is only turned on when vectorization is on, but may also
> depend on the optimization level. Currently, the logic to handle this
> is in the gate function which become hard to understand and extend.
> The proposed patch move the logic from the gate function to
> 'finish_option' which is much clearer. The downside of this patch is
> that function specific optimization node needs to be created for some
> cases during omp-lowering.
Something I don't like. What's the issue with checking the
How's the argument that the gate is hard to extend? Wouldn't
extending it complicate it again and thus make it hard to understand again?
That said, given that doing things in finish_options () is discouraged
the patch looks like a step backwards.
So, can you explain the underlying rationale?
Btw, if we think of if-conversion as tied to loop vectorization then we can
guard it by it and make a new container pass like
and guard pass_loop_vectorizer by flag_tree_loop_vectorize, defaulting
if-conversion to be enabled (but allow disabling it manually).
Or take the step and move it under control of the vectorizer itself.