<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Ralf,<div><br></div><div><div><blockquote type="cite"><div>The project started as a use-case for our "Whole-Function Vectorization" <br>library, which allows to transform a function to compute the same as W <br>executions of the original code by using SIMD instructions (W = 4 for <br>SSE/AltiVec, 8 for AVX).<br></div></blockquote><div><br></div><div>Quite interesting. We were planning to add "vectorization" to our passes also, but if I understood the paper correctly your approach uses full speculation, which is all right for SIMD architectures but might not be so for multi-issue processors. The pocl project comes from a generalization of our work in using OpenCL as entry language for static ILP architectures (<a href="http://dx.doi.org/10.1109/ICSAMOS.2010.5642061">http://dx.doi.org/10.1109/ICSAMOS.2010.5642061</a>), so we do not only focus on DLP but also ILP (ultimate goal of pocl is portable performance of OpenCL code among different platforms).</div><div><br></div><div>Our idea was to use an hybrid method, with vectorized code in the unconditional sections and replicated/looped as we do now on the conditional parts of the kernels.</div><div><br></div><blockquote type="cite"><div>In contrast to Clover and pocl, we aimed at maximum performance before <br>full support of the API (which simply requires more manpower than one <br>PhD student).<br></div></blockquote><div><br></div><div>That is wrong, at least for pocl. We do not (by far) support the whole API, the main new point on pocl is the LLVM passes to statically create the different work items in a workgroup, and the barrier handling. Our kernel runtime library is currently in fact fairly small, including just a little more then the implementation-dependent functions. We are considering merging efforts with liblcl in that point.</div><div><br></div><div>BR,</div><div><br></div><div>Carlos</div><div><br></div><blockquote type="cite"><div>Am 19.10.2011 17:38, schrieb Hal Finkel:<br><blockquote type="cite">Do we have a list of these open-source LLVM-based OpenCL projects<br></blockquote><blockquote type="cite">somewhere? Off the top of my head, we have:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">libclc: <a href="http://www.pcc.me.uk/~peter/libclc/">http://www.pcc.me.uk/~peter/libclc/</a><br></blockquote><blockquote type="cite">pocl: <a href="https://launchpad.net/pocl">https://launchpad.net/pocl</a><br></blockquote><blockquote type="cite">clover: <a href="http://cgit.freedesktop.org/~steckdenis/clover/">http://cgit.freedesktop.org/~steckdenis/clover/</a><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">(I think that all of these have BSD- or MIT-style licenses).<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Are there any others?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">  -Hal<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On Wed, 2011-10-19 at 14:47 +0100, Peter Collingbourne wrote:<br></blockquote><blockquote type="cite"><blockquote type="cite">Hi,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">This is to announce the availability of libclc, an open source, BSD<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">licensed implementation of the library requirements of the OpenCL C<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">programming language, as specified by the OpenCL 1.1 Specification.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">libclc is intended to be used with Clang's OpenCL frontend.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">libclc website: <a href="http://www.pcc.me.uk/~peter/libclc/">http://www.pcc.me.uk/~peter/libclc/</a><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">libclc is designed to be portable and extensible. To this end,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">it provides generic implementations of most library requirements,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">allowing the target to override the generic implementation at the<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">granularity of individual functions.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">libclc currently only supports the PTX target, but support for more<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">targets is welcome.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">How does this project relate to the recently announced Portable OpenCL<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">(POCL) project?  Unlike POCL, this project is not intended to provide<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">an OpenCL host library (i.e. the OpenCL Platform Layer and OpenCL<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Runtime specified in sections 4-5 of the OpenCL specification).<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Instead, it provides only the requirements for the OpenCL C<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Programming Language (section 6 et seq).  It is intended to be used<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">with an existing host library implementation, and comply with its<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">ABI requirements.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">An example of such a host library is NVIDIA's OpenCL host library<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">for PTX -- the intention is to at some point provide a mechanism<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">for using the NVIDIA implementation of OpenCL with Clang, libclc<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">and LLVM's PTX backend instead of NVIDIA's own OpenCL compiler.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Another example would be POCL's host library, and the POCL developers<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">have expressed an interest in using libclc as their OpenCL C library<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">instead of developing their own.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">I will hope to find time over the next few weeks to add libclc support<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">to the Clang driver.  The intention is that compiling OpenCL C programs<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">to PTX would be as easy as (something like this):<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">clang -target ptx32 -S file.cl<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">such that the driver would automatically locate the libclc headers,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">add them to the include path and pre-include the main header file.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">(The libclc support will of course be optional, and a -cl-stdlib=<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">flag will be provided to allow for switching between OpenCL standard<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">library implementations.)<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Thanks,<br></blockquote></blockquote><blockquote type="cite"><br></blockquote>_______________________________________________<br>LLVM Developers mailing list<br><a href="mailto:LLVMdev@cs.uiuc.edu">LLVMdev@cs.uiuc.edu</a>         <a href="http://llvm.cs.uiuc.edu">http://llvm.cs.uiuc.edu</a><br><a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br></div></blockquote></div><br></div></body></html>