<div dir="ltr"><div><div><div><div><div>Hi Andrey,<br><br></div>This helped but this is not working with polly. If I don't include the "-fopenmp=libomp", then polly is able to do its specified optimizations, but if I include this flag, I cannot use polly anymore. <br><br></div>I found something-: <a href="https://github.com/clang-omp/clang/issues/44">https://github.com/clang-omp/clang/issues/44</a> which mentions using clang-omp with polly. But, I am not sure.<br><br></div>Can you guys help in this?<br><br></div>Thanks,<br></div>Rajat<br><div><div><div> <br><div><br><br></div></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jul 15, 2015 at 10:46 AM, 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">Rajat,<br>
<br>
Glad this helped.<br>
<br>
As for mentioning "-fopenmp=libomp", today we got one step closer for<br>
making libomp the default value. So maybe it will go for good soon?<br>
<span class="HOEnZb"><font color="#888888"><br>
Andrey<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
On Wed, Jul 15, 2015 at 4:43 PM, Rajat Garg <<a href="mailto:gargx093@umn.edu">gargx093@umn.edu</a>> wrote:<br>
> Hi,<br>
><br>
> Thanks a lot for mentioning "-fopenmp=libomp". This works perfectly fine.<br>
> Maybe you should should mention this on <a href="http://openmp.llvm.org/" rel="noreferrer" target="_blank">http://openmp.llvm.org/</a>. I have been<br>
> dealing with this for last two days.<br>
><br>
><br>
> Thanks,<br>
> Rajat<br>
><br>
> On Tue, Jul 14, 2015 at 5:37 PM, Andrey Bokhanko <<a href="mailto:andreybokhanko@gmail.com">andreybokhanko@gmail.com</a>><br>
> wrote:<br>
>><br>
>> 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>
>><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<br>
>> > 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<br>
>> > tried<br>
>> > to compile a simple program with #pragma parallel. But I could not<br>
>> > create<br>
>> > more than one thread. This was because libgomp was getting linked<br>
>> > 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>
>> > _______________________________________________<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>
><br>
><br>
><br>
><br>
> --<br>
> Rajat<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr">Rajat</div></div>
</div>