[Openmp-dev] Problem in setting number of threads while using clang with openmp

Tobias Grosser tobias at grosser.es
Wed Jul 15 09:04:39 PDT 2015


On 07/15/2015 05:35 PM, Rajat Garg wrote:
> Hi Andrey,
>
> 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.
>
> I found something-: https://github.com/clang-omp/clang/issues/44 which
> mentions using clang-omp with polly. But, I am not sure.
>
> Can you guys help in this?

Hi Rajat,

for obvious reasons it would be best if you could provide a minimal test 
case.

Here at least a first guess: if you enable -fopenmp, clang will already 
outline the parts marked 'omp parallel' into openmp runtime calls. Polly 
does currently not see of look into such calls and consequently is not 
able to modify/transform this code.

There is however some recent work that uses Polly to further optimize 
OpenMP parallel programs:

http://impact.gforge.inria.fr/impact2015/papers/impact2015-chatarasi.pdf

This is a first workshop version, but there may also be a conference 
version of this paper be published.

Best,
Tobias



More information about the Openmp-dev mailing list