Showing posts with label London. Show all posts
Showing posts with label London. Show all posts

Tuesday, September 25, 2012

Finally Holidays... and some GPU code!

During the next week I'll be visiting London.


In the meanwhile enjoy a code preview of A GPU Exercise part 1 and part 2, and stay tuned for part 3 :)

To get, compile, and test the code, clone my funproject repository on github.
git clone git://github.com/cybercase/funproject.git
To compile the code is required the NVIDIA CUDA Toolkit. Then run:
cd funproject
cmake .
make
If CUDA Toolkit was found by CMake, then the lev_distance target should be built into the experiments directory. To quickly test the performances run:
cd experiments
./lev_distance lev_distance.cu thread.h
The following result is achieved on my late 2010 MBA
lev_distance.cu size is 8716 bytes
thread.h size is 17818 bytes
LevDistance...
elapsed time: 9.240 (s)
CudaLevDistance...
elapsed time: 0.872 (s)
Results matches!
Distance: 14332
Please note that this is an educational implementation, and several improvements can be done to exploit all the features of the underlying architecture...

But before talking about this... holidays! :)