Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/markusn/bfer
Brainfuck to LLVM IR compiler written in Erlang
https://github.com/markusn/bfer
brainfuck erlang llvm
Last synced: about 1 month ago
JSON representation
Brainfuck to LLVM IR compiler written in Erlang
- Host: GitHub
- URL: https://github.com/markusn/bfer
- Owner: markusn
- License: other
- Created: 2013-08-23T22:59:37.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2024-01-05T12:57:48.000Z (11 months ago)
- Last Synced: 2024-10-08T15:17:50.722Z (about 1 month ago)
- Topics: brainfuck, erlang, llvm
- Language: Erlang
- Size: 198 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: COPYING
Awesome Lists containing this project
README
bfer
==========
[![Build Status](https://travis-ci.org/markusn/bfer.png?branch=master)](https://travis-ci.org/markusn/bfer)
[![Coverage Status](https://coveralls.io/repos/markusn/bfer/badge.png?branch=master)](https://coveralls.io/r/markusn/bfer?branch=master)Brainfuck to LLVM IR compiler written in Erlang.
## Building
To build as a library to be included in another Erlang project:
```bash
rebar compile
```To build as a standalone escript:
```bash
rebar compile escriptize
```## Usage
When using as a library in another Erlang module the main entry point is `bfer_lib:compile/2` which
takes Brainfuck code as a string and returns LLVM IR as a string.Used as a standalone escript `bfer` can generate native code if llvm and some kind of cc is installed:
```bash
bfer [-o] INPUT.bf OUTPUT
```Specifying -o "optimizes" the generated LLVM IR.
## Author
Markus Ekholm (markus at botten dot org).## License
3-clause BSD. For details see `COPYING`.