[LLVMdev] LLVM Loop Vectorizer puzzle
schnetter at cct.lsu.edu
Thu May 23 12:28:11 PDT 2013
On Thu, May 23, 2013 at 1:26 PM, Nadav Rotem <nrotem at apple.com> wrote:
> On May 23, 2013, at 10:37 AM, Cameron McInally <cameron.mcinally at nyu.edu>
> In all fairness, I do not believe that ivdep is an ICC-specific pragma.
> There are many compilers that support ivdep and lots of legacy (and modern)
> codes that benefit from it. Seems silly, to me at least, to reinvent the
> Hi Cameron,
> The history of the idvep pragma is fascinating. I did not know that it
> predated ANSI. People who care about cray compatibility should provide
> aliases for #ivdep. The name “ivdep” is simply terrible. There is no good
> reason not to come up with a syntax that is actually meaningful to people.
> I like arnold’s idea to add additional options so the ‘vector’ pragma.
Clang is (still) way behind the curve when it comes to expressing
parallelism. Most other compilers support this out of the box, and there is
a large body of code that uses such pragmas, be they "nice" or "cryptic".
It's unfortunate that there is no ANSI or equivalent standard for ivdep,
but the compiler manuals combined plus large bodies of existing code
provide a de-facto community standard.
If you are looking for a real standard to follow -- and that would be much
better than defining a clang-specific extension -- then I suggest OpenMP's
"#pragma omp simd". See e.g. <
which discusses multi-threading vs. vectorization, or <
Erik Schnetter <schnetter at cct.lsu.edu>
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev