[LLVMdev] LoopVectorizer in OpenCL C work group autovectorization
Chareos at gmx.de
Thu Jan 31 23:45:30 PST 2013
On 1/31/13 6:15 PM, Pekka Jääskeläinen wrote:
>> On the other hand, LoopVectorizer may not be aimed at covering all kinds
>> of code inside the body and/or instead focus more on things not required
>> by WFV, such as handling reductions and other kinds of loop-carried
> It is true that the feature set of the LoopVectorizer goes beyond the
> "embarrassingly parallel loops" that the implicit WI loops are. However,
> I don't see this as a show-stopper for trying to provide a modularized
> approach to work group vectorization.
> Moreover, parallelization-helping optimizations such as "loop masking" for
> the diverging inner-loops (kernel loops) are more generally useful, and,
> should be added to LLVM upstream (not to an OpenCL implementation only)
> eventually as generic loop vectorization routines.
Yes, I fully agree. I already told Nadav that he will immediately get
access to my new implementation when he reaches that point to prevent
him from re-implementing everything (or at least to have some code to
refer to ;) ). The code is not released yet, but it is under LLVM
license so there's no problem with that.
>> In any case, since our own OpenCL driver is more of a proof-of-concept
>> implementation and not very robust, I'd be willing to give it a try to
>> integrate the current libWFV into pocl. This should boost performance
>> quite a bit for many kernels without too much effort ;). I just don't
>> know (yet) where to start - can you give me a hint, Pekka?
> I'm very glad to hear this! Luckily, the pocl code base has been
> to allow easily switching the "work group function generation method"
> which I
> think your WFV work actually is.
> Perhaps the detailed instructions on how to start are out of topic here and
> you might want to join the pocl-devel list (and #pocl) where the pocl
> developers can give more hints. See
I'll do this now :).
More information about the llvm-dev