Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zshipko/futhark-bindgen
A Futhark binding generator for Rust and OCaml
https://github.com/zshipko/futhark-bindgen
futhark ocaml rust
Last synced: 24 days ago
JSON representation
A Futhark binding generator for Rust and OCaml
- Host: GitHub
- URL: https://github.com/zshipko/futhark-bindgen
- Owner: zshipko
- License: isc
- Created: 2022-07-24T06:32:32.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-02-10T17:01:58.000Z (9 months ago)
- Last Synced: 2024-10-14T01:42:08.235Z (about 1 month ago)
- Topics: futhark, ocaml, rust
- Language: Rust
- Homepage:
- Size: 125 KB
- Stars: 27
- Watchers: 3
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGES.md
- License: LICENSE.md
Awesome Lists containing this project
README
# futhark-bindgen
A [Futhark](https://futhark-lang.org) binding generator.
`futhark-bindgen` uses the [manifest](https://futhark.readthedocs.io/en/latest/c-api.html#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
- [Rust](https://github.com/zshipko/futhark-bindgen/tree/main/examples/rust)
- [OCaml](https://github.com/zshipko/futhark-bindgen/tree/main/examples/ocaml)