FFI binding to the CUDA interface for programming NVIDIA GPUs

Latest on Hackage:

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow to host generated Haddocks.

BSD3 licensed and maintained by Trevor L. McDonell

Haskell FFI Bindings to CUDA

Build status

The CUDA library provides a direct, general purpose C-like SPMD programming model for NVIDIA graphics cards (G8x series onwards). This is a collection of bindings to allow you to call and control, although not write, such functions from Haskell-land. You will need to install the CUDA driver and developer toolkit.

The configure step will look for your CUDA installation in the standard places, and if the nvcc compiler is found in your PATH, relative to that.

For important information on installing on Windows, see:


  • Bug fix in occupancy calculator

  • Bug fixes: #43, #45, #47

  • Re-enable support for Cabal-1.22

  • Bug fixes: #40, #44

  • Add support for CUDA-7.5

  • mallocHostForeignPtr

  • Add profiler control functions

  • Add support for operations from CUDA-7.0

  • Add support for online linking

  • Add support for inter-process communication

  • Bug fixes, extra documentation, improve library coverage.

  • Mac OS X no longer requires the DYLDLIBRARYPATH environment variable in order to compile or run programs that use this package.

  • Add support for building on Windows (thanks to mwu-tow)

  • Build fix

  • Build fixes for ghc-7.6 and ghc-7.10

  • Drop support for CUDA 3.0 and older.

  • Combine the definition of the 'Event' and 'Stream' data types. As of CUDA-3.1 these data structures are equivalent, and can be safely shared between runtime and driver API calls and libraries.

  • Mark FFI imports of potentially long-running API functions as safe. This allows them to be safely called from Haskell threads without blocking the entire HEC.

  • Add compute-capability data for 3.7, 5.2 devices.

  • Build fix for Mac OS X 10.10 (Yosemite)

  • Add support for the CUDA-6.5 release

comments powered byDisqus