On Thu, Sep 14, 2017 at 4:05 PM, Richard Sandiford <richard.sandif...@linaro.org> wrote: > Richard Biener <richard.guent...@gmail.com> writes: >> On Thu, Sep 14, 2017 at 1:23 PM, Richard Sandiford >> <richard.sandif...@linaro.org> wrote: >>> This patch adds a helper function for getting the number of >>> bytes accessed by a scalar data reference, which helps when general >>> modes have a variable size. >>> >>> Tested on aarch64-linux-gnu, x86_64-linux-gnu and powerpc64le-linux-gnu. >>> OK to install? >> >> Can you put it into tree-data-ref.h? > > The idea (which I forgot to say) was to collect the uses within the > vectoriser into one place so that we can assert in only one place > that the reference is constant-sized. > > A general data_reference can be variable-sized, so the guarantees > wouldn't be the same elsewhere. > > Would putting it in tree-vectorizer.h be OK?
Maybe name it vect_get_scalar_dr_size then? Ok with that. Richard. > Thanks, > Richard