<div dir="ltr">Hi,<br><div><br>Thanks a lot for mentioning "-fopenmp=libomp". This works perfectly fine. Maybe you should should mention this on <a href="http://openmp.llvm.org/">http://openmp.llvm.org/</a>. I have been dealing with this for last two days.<br><br><br></div><div>Thanks,<br></div><div>Rajat<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 14, 2015 at 5:37 PM, Andrey Bokhanko <span dir="ltr"><<a href="mailto:andreybokhanko@gmail.com" target="_blank">andreybokhanko@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Rajat,<br>
<br>
OpenMP 3.1 is fully upstreamed to clang / llvm trunk, so it is better<br>
to use trunk version (unless you have a really good reason to prefer<br>
one hosted on clang-omp.github).<br>
<br>
Instructions are posted on llvm blog:<br>
<a href="http://blog.llvm.org/2015/05/openmp-support_22.html" rel="noreferrer" target="_blank">http://blog.llvm.org/2015/05/openmp-support_22.html</a>. The only<br>
difference is that instead of "-fopenmp" you should use<br>
"-fopenmp=libomp" (this is temporary and will be fixed, but here we<br>
are).<br>
<br>
As for the segmentation fault you got, please try trunk version of the<br>
compiler and if problem won't go away, provide more details: HW and OS<br>
you use, how exactly you built clang, what's inside try.c, etc.<br>
<br>
Yours,<br>
Andrey Bokhanko<br>
=============<br>
Software Engineer<br>
Intel Compiler Team<br>
Intel<br>
<div><div class="h5"><br>
<br>
On Tue, Jul 14, 2015 at 9:03 PM, Rajat Garg <<a href="mailto:gargx093@umn.edu">gargx093@umn.edu</a>> wrote:<br>
> Hi,<br>
><br>
> I am using the clang provided by polly(which is version 3.7) in association<br>
> with openmp shared library(<a href="http://openmp.llvm.org/" rel="noreferrer" target="_blank">http://openmp.llvm.org/</a>).<br>
><br>
> Ultimately, I have to run clang with polly on multiple threads. So, I tried<br>
> to compile a simple program with #pragma parallel. But I could not create<br>
> more than one thread. This was because libgomp was getting linked instead of<br>
> libomp.<br>
><br>
> So, as suggested on <a href="https://github.com/clang-omp/clang/issues/44" rel="noreferrer" target="_blank">https://github.com/clang-omp/clang/issues/44</a>, I<br>
> downloaded the clang-omp version and following the directions as in<br>
> <a href="https://clang-omp.github.io/" rel="noreferrer" target="_blank">https://clang-omp.github.io/</a>.<br>
><br>
> ../build/bin/clang-3.5 -fopenmp<br>
> -L/home/rajat/lulesh/openmp/runtime/exports/lin_32e/lib/<br>
> -I/home/rajat/lulesh/openmp/runtime/exports/common/include try.c<br>
><br>
> But, this gives segmentation fault with #pragma omp parallel.<br>
><br>
> Can you help me out in this.<br>
><br>
> Thanks,<br>
> Rajat<br>
><br>
</div></div>> _______________________________________________<br>
> Openmp-dev mailing list<br>
> <a href="mailto:Openmp-dev@dcs-maillist2.engr.illinois.edu">Openmp-dev@dcs-maillist2.engr.illinois.edu</a><br>
> <a href="http://lists.cs.uiuc.edu/mailman/listinfo/openmp-dev" rel="noreferrer" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/openmp-dev</a><br>
><br>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr">Rajat</div></div>
</div>