Over a million developers have joined DZone.

Why You Should Be Interested in Futhark

DZone's Guide to

Why You Should Be Interested in Futhark

Researchers at the University of Copenhagen’s Department of Computer Science have officially released their new functional programming language called Futhark. It is designed to run on a GPU for machine learning and other high-performance applications. Read on for more information.

· Performance Zone
Free Resource

Transform incident management with machine learning and analytics to help you maintain optimal performance and availability while keeping pace with the growing demands of digital business with this eBook, brought to you in partnership with BMC.

Researchers at the University of Copenhagen’s Department of Computer Science have officially released their new functional programming language called Futhark. This new programming language—which is free and open source—is designed to run on a GPU for machine learning and other high-performance applications.

The common method for GPU programming involves using frameworks like OpenCL or CUDA, both of which are variations of C or C++. Furthark can generate C code, but it is actually its own language. You can relate this new language to Haskell (Furthark is written in Haskell).

The language developers claim that the more expressive a language is, the easier it is to describe complex operations that use parallelism. This includes the support for nested parallelizations (parallel operations inside other parallel operations).

The Futhark Developers stated:

Futhark can do this despite the complexities of efficiently mapping to the flat parallelism supported by hardware, as a great many programs depend on this feature.

Futhark GPU programs were put to the test. When put against other GPU libraries, they showed mixed but some pretty promising results. For the maximum segment sum test, it matched or was only slightly slower, than the competition. The developers thought that this was attributed to the newness of the language and the unrefined results for memory usage and allocation.

The current toolchain can generate code capable of running on the CPU or GPU, with a good variety of targets. For the former, it will generate C code compiled by the CGG; for the latter it will compile C code that uses the OpenCL platform. This will allow the code to run on whichever hardware is available to support it.

For Python developers and coders who want a speed boost, they will be able to generate code with Futhark wrapped in a Python module. This code will run via PyOpenCL, which is a library that interfaces with GPUs. There are examples of this, such as a Futhark-driven GPU implementation of Conway’s Game of Life.

Please remember that at the time of writing this article, Futhark is still currently a research project; it is not as polished or complete as other languages. The current documentation is incomplete, but both the docs and language are open source on GitHub.

Evolve your approach to Application Performance Monitoring by adopting five best practices that are outlined and explored in this e-book, brought to you in partnership with BMC.

big data ,programming ,coding ,programming languages ,programming frameworks ,frameworks ,functional languages ,functional programming

Published at DZone with permission of Traven West, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.


Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.


{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}