How to read .cu files (dragon.cu?) that accelerate generates.
Takayuki Muranushi
muranushi at gmail.com
Tue Dec 14 11:12:23 EST 2010
2010/12/13 Manuel M T Chakravarty <mchakravarty at mac.com>:
> Takayuki Muranushi:
>> Nice to meet you, let me make a first question.
>>
>> Today, I succeeded in installing Accelerate in GPU machine and running
>> examples. This project is very interesting!
>> To begin with, I'm going to write my samples and see how they work. As
>> doing so, it'll be helpful if I could see what kind of codes are being
>> generated and how they change as I change the Haskell programs. At the
>> moment, I guess Accelerate is removing .cu files it generates because
>> I can't find them.
>>
>> So, is there an easy way to make Accelerate keep the files? Or, shall
>> I modify Compile.hs or something, to do that?
>
> Which version of Accelerate are you using? You might want to have a look at accelerate.cabal (in the toplevel directory). There are various options that you can pass during the configure step (when compiling the library). On of the more recent options is 'pcache'. If you pass the option '-fpcache' to configure, Accelerate will keep the generated kernels in a subdirectory called "cache".
>
> We have also got a paper describing code generation in some detail:
>
> http://justtesting.org/final-version-of-the-accelerate-paper-gpgpu-i
>
> I hope that helps.
>
> Cheers,
> Manuel
>
>
Dear Manuel,
Thank you for your response. I'm using 0.8.2.0 (took it from the darcs
repository.)
Now I looked at the .cabal and found the option, that resolves my
problem. Thankyou!
First of all I had hard time figuring out how to have Accelerate
generate CUDA codes...
until I found "cuda" flag in .cabal . It'll be helpful for people like
me if you include some
mentions about the options in README in the future.
Also I found out that by default, the generated file are put under /tmp .
I'll read the paper. Thank you for introduction!
Best,
--
MURANUSHI Takayuki
The Hakubi Center, Kyoto University
More information about the Accelerate
mailing list