• Stars
    star
    154
  • Rank 234,234 (Top 5 %)
  • Language
  • Created over 12 years ago
  • Updated over 12 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A brainfuck compiler, written in sed
      ########################################################
      ##                                                    ##
      ##                      bf.sed                        ##
      ##                                                    ##
      ##       an optimising compiler for brainfuck         ##
      ##          produces x86 Linux ELF binaries           ##
      ##              written entirely in sed               ##
      ##                                                    ##
      ########################################################

This is a compiler for the minimalist brainfuck programming language.
There's a description of how it works in the comments, and a few
example brainfuck files in this repo.

The brainfuck code is taken from examples on Wikipedia and programs on
www.muppetlabs.com/~breadbox/bf and esoteric.sange.fi/brainfuck.

If you have an urge to see the assembly produced by this script, I
recommend installing nasm and using "ndisasm -u -e 84 $output".

I would not recommend sed as a compiler implementation language, but
it's definitely in keeping with the spirit of brainfuck.

More Repositories

1

jq

Command-line JSON processor
C
21,280
star
2

malfunction

Malfunctional Programming
OCaml
318
star
3

counterexamples

Counterexamples in Type Systems
JavaScript
281
star
4

mlsub

Prototype type inference engine
OCaml
181
star
5

crowbar

Property fuzzing for OCaml
OCaml
174
star
6

ppx_stage

Staged metaprogramming in stock OCaml
OCaml
142
star
7

idris-malfunction

Experimental Malfunction backend for Idris
Haskell
82
star
8

caml-oxide

safe FFI between OCaml and Rust (experimental)
Rust
64
star
9

minhttp

A tiny and surprisingly featureful webserver
C
49
star
10

git-ls

List files, annotated by git status
Python
36
star
11

pathfinder

pythonic filesystem library
Python
35
star
12

hax

Random scripts, snippets of code, whatever.
Java
23
star
13

libfib

A library for high-performance lightweight threads
C++
19
star
14

llvm

Context switching for LLVM
C++
15
star
15

linkage

easy-to-use wrapper for OCaml's Dynlink
OCaml
15
star
16

ocaml-afl-persistent

persistent-mode afl-fuzz for ocaml
OCaml
14
star
17

Sandbox

Sandbox for running native code under Linux at full speed, without allowing it to do anything other than read/write stdio
C
12
star
18

bzseek

Random access library for bzip2 files
C
8
star
19

cshore

Call C from Python without writing bindings
C
8
star
20

moria

Embedded language for construction of DWARF
OCaml
7
star
21

with-gdb

Attaches gdb to crashed processes
C
7
star
22

nd

Netsoc LDAP directory
Python
6
star
23

wikiflow

random walks through human knowledge
5
star
24

fyp

Final year project
Haskell
5
star
25

python-monkeypatch

Bringing Ruby best practices to Python
Python
5
star
26

Altitude

Debugging above C level
C
4
star
27

clang

Clang C/C++ compiler, with patches to support context-switching
C++
4
star
28

sequent-subtyping

Coq
3
star
29

irclinks

IRC network visualisation
Python
3
star
30

seqbuf

Sequential buffer access
OCaml
3
star
31

sneeky

Steganography through bad spelling
Python
2
star
32

bandgraph

Scale-space visualisation of time-series data
Python
2
star