This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Fix PR62283
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: Richard Biener <rguenther at suse dot de>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 29 Apr 2015 19:26:23 -0700
- Subject: Re: [PATCH] Fix PR62283
- Authentication-results: sourceware.org; auth=none
- References: <alpine dot LSU dot 2 dot 11 dot 1504281027040 dot 20496 at zhemvz dot fhfr dot qr>
On Tue, Apr 28, 2015 at 1:29 AM, Richard Biener <email@example.com> wrote:
> The following fixes a missed optimization in basic-block vectorization.
> Currently we require the SLP chain to end up in a sequence of loads
> we support. But of course we can in theory end the SLP chain at
> any point and simply construct the vector operand of the uses by
> pieces. This is what the patch does to handle the case where
> "external" defs are not really external. As the patch is somewhat
> more generic it also handles more cases and relies on the cost model
> to reject the outright non-profitable ones (like the bb-slp-14.c
> case which is run with -fno-vect-cost-model though).
> Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to trunk.
> 2015-04-28 Richard Biener <firstname.lastname@example.org>
> PR tree-optimization/62283
> * tree-vect-slp.c (vect_build_slp_tree): When the SLP build
> fails fatally and we are vectorizing a basic-block simply
> cause the child to be constructed piecewise.
> (vect_analyze_slp_cost_1): Adjust.
> (vect_detect_hybrid_slp_stmts): Likewise.
> (vect_bb_slp_scalar_cost): Likewise.
> (vect_get_constant_vectors): For piecewise constructed
> constants place them after the last def.
> (vect_get_slp_defs): Adjust.
> * tree-vect-stmts.c (vect_is_simple_use): Detect in-BB
> externals for basic-block vectorization.