[LLVMdev] SPMD Autovectorizer

Pekka Jääskeläinen pekka.jaaskelainen at tut.fi
Tue Jul 7 02:16:29 PDT 2015


On 07/06/2015 09:40 PM, Hal Finkel wrote:
> I don't know of any concrete plans, but this is something I'd still
> like to see happen. If no one gets to it first, I may even work on it
> at some point.

The pocl's kernel compiler's parallel region analysis
could also provide for a starting point. It generates parallel
loops out from the regions between barriers via static
analysis which the vectorizers then vectorize/parallelize as
they see fit for the target at hand (with assistance from
the parallel loop annotations).

The loops could even be converted (selectively) to OpenMP
parallel loops for flexible parallelization when there are
not too many work items and an SMP target has multiple cores,
etc. The point is that the way those loops are mapped to
hardware is up to other (target dependent) passes(*).

However, the current upstream version is somewhat rusty with
some known issues, and I'd like to try to find time after
the summer to clean up an experimental private version and
push it to pocl master.

Maybe that could serve as a basis for LLVM upstreaming?
Previously I've assumed that this part of the pocl kernel
compiler could not be easily upstreamed to LLVM as it's
not needed for C/C++ (and someone said other languages
such as OpenCL C are very low priority), but if there's
interest, I'd be happy to get that part upstreamed
as well.

(*) http://link.springer.com/article/10.1007/s10766-014-0320-y

BR,
-- 
--Pekka



More information about the llvm-dev mailing list