11 releases

0.2.8 Feb 10, 2024
0.2.7 Jan 5, 2024
0.2.6 Dec 5, 2023
0.2.5 Sep 9, 2022
0.1.1 Aug 2, 2022

#80 in FFI

Download history 3/week @ 2024-01-03 5/week @ 2024-02-14 21/week @ 2024-02-21 9/week @ 2024-02-28 2/week @ 2024-03-06 6/week @ 2024-03-13 24/week @ 2024-03-27 46/week @ 2024-04-03

77 downloads per month

ISC license

79KB
2K SLoC

Rust 1.5K SLoC // 0.0% comments OCaml 250 SLoC // 0.1% comments

futhark-bindgen

A Futhark binding generator.

futhark-bindgen uses the manifest created by Futhark to generate bindings for multiple languages.

Supported languages:

  • Rust
  • OCaml

Installation

With cargo:

$ cargo install futhark-bindgen

From source:

$ make install PREFIX=~/.local/bin

Command-line usage

$ futhark-bindgen run test.fut test.rs # Rust output to ./test.rs
$ futhark-bindgen run test.fut test.ml # OCaml output to ./test.ml

The --backend flag can be used to select which Futhark backend to use: c, multicore, cuda, opencl or ispc

See the output of futhark-bindgen --help for more information

Example projects

Dependencies

~0.7–1.5MB
~33K SLoC