Hope never ends! We can always try the following approaches:
2. Use Scala as the front end and write CUDA backend in C++. Then build the scala-c++ interface (wrapper) automatically by SWIG.
3. Find a Java-based library, then call it from Scala. (I think this is the easiest way, and I will discuss this in details in my next post)
Scala is compatible with Java:
-The standard backend Scala is Java VM. Scala classes are Java classes, and vice versa. You can call the methods of either language from methods in the other one. You can extend Java classes in Scala, and vice versa.
-Scala classes become same-named Java classes. Scala classes can subclass Java classes, you can instantiate Java classes in Scala.
-The main limitation is that some Scala features do not have equivalent in Java. Accessing Java classes from Scala is no problem at all, while using a Scala class from Java can be tricky.
4. Breeze author David also has a github project on cuda binding in scala.
scala-jcuda example: a problematic one another scalalab