[LLVMdev] translating from OpenMP to CUDA

Dmitry N. Mikushin maemarcus at gmail.com
Fri Nov 9 14:35:56 PST 2012


Dear Apala,

Have you heard of OpenACC? That's an OpenMP-like set of directives
specially tuned for accelerators: data regions, implicit or explicit
memory copyins/copyouts, gangs/vectors, etc. Developing your idea
further, in fact, leads to implementing an OpenACC frontend for LLVM.
PTX backend is definitely a necessary ingredient. Besides it, at some
point you would still need to develop a loop analysis system. Two
projects are doing related work: Polly [1] and KernelGen [2,3].

[1] http://polly.llvm.org/
[2] http://kernelgen.org/
[3] http://kernelgen.org/ncar2012/

2012/11/9 Justin Holewinski <justin.holewinski at gmail.com>:
> The PTX back-end is robust (it's based on the sources used by nvcc), but I'm
> not sure about the OpenMP representation in LLVM IR.  I believe the OpenMP
> constructs are already lowered into libgomp calls before leaving DragonEgg.
> It's been awhile since I've loooked at it though.
>
> If you use the PTX back-end and have any issues, please don't hesitate to
> post to the list and cc: me at jholewinski at nvidia.com
>
>
> On Thu, Nov 8, 2012 at 8:05 AM, Apala Guha <aguha at uchicago.edu> wrote:
>>
>> Hi,
>>
>>
>>
>> Is it possible to translate an OpenMP program to CUDA using LLVM? I read
>> that dragonegg has a OpenMP front-end and LLVM has a PTX back-end. I don’t
>> know how mature these tools are. Please let me know. Thanks.
>>
>>
>>
>> -Apala
>>
>>
>>
>> Postdoctoral Scholar
>>
>> Department of Computer Science, University of Chicago
>>
>> Computation Institute, Argonne National Laboratory
>>
>> http://sites.google.com/site/apalaguha/home/
>>
>>
>>
>>
>> _______________________________________________
>> LLVM Developers mailing list
>> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>>
>
>
>
> --
>
> Thanks,
>
> Justin Holewinski
>
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>




More information about the llvm-dev mailing list