Brainfuck Developer

What is it?

BFdev running

Brainfuck Developer is a Win32 tool for writing, debugging, and (in some degree) understanding Brainfuck programs. Its main feature is an integrated debugger with support for single-step trace, run-to-cursor, and interactive memory inspection. It is a development tool, not only a simple interpreter.

With the "Watch Program Operation" feature, you can watch your BF code running to go get an impression what your program does. In addition, BFdev features "piping" input and output data to files. You can set an input file from which the input data is read, and an output file to which all output data is written (in binary). Given this ability, BFdev is just as powerful as console interpreters.

Since version 1.4.0, BFdev supports the pbrain (procedural brainfuck) language extension. This extension adds three new commands to the BF language (as explained below). A very useful feature integrated in BFdev since version 1.4.6 is the Text Generator, a tool that generates BF code for printing text.

There is nothing to say about how BFdev works. Everyone who has already worked with an IDE like Visual Studio, Delphi, or Turbo Pascal knows the basic functioning of BFdev. (To those who have not: do you really wanna code Brainfuck? ;) All of the program's functions are self-explanatory.

The screenshot to the right shows BFdev in debug mode, running "factor.b" by Brian Raiter.

Technical details

For Brainfuck programs, the interpreter provides the following "virtual machine":


Brainfuck Developer is freeware. That means, you may distribute it freely, but only in "complete and unchanged state" and NOT ON YOUR OWN WEBSITE. BFdev is "complete" with the three files bfdev.exe, printer.b, and readme.txt, bundled in the original bfdev.zip file. FREEWARE DOES NOT MEAN PUBLIC DOMAIN OR OPEN SOURCE. I hold all rights.

Why isn't BFdev open source? I cannot release BFdev as open source since the code is an embarassment for me. BFdev started as a very small project and was not meant to grow as it finally did. I added more and more functionality, but the architecture was not really capable of supporting this. The program appears small, but internally, there's more code than one might think. Bad code, unfortunately. I feel pain when looking at it. I should rewrite the whole thing.

To webmasters: DO NOT link to the zip-files directly and DO NOT upload the files to your webserver! Instead, link to 4mhz.de or 4mhz.de/bfdev.html. Thanks.

Feedback is always appreciated, especially if you encounter any bugs or have any ideas for the next version.

Important for programmers: If you write a program like ,>, and enter a text like "a", please don't be confused if BFdev only asks for just one input instead of two! This is NO BUG, it's a feature. In text input mode, BFdev may append a new-line code to your input, so that the second , reads this new-line code. You can change this behaviour in the "Interpreter" menu. (Well... given this explanation, I hope no one will complain anymore...)

Some hints for using BFdev

The pbrain language extension

pbrain means "procedural brainfuck" and enables you to define and call procedures in your BF programs. For this purpose, pbrain adds three new commands to the BF language: "(", ")", and ":".

BFdev does not tolerate calling of undefined procedures. In this case, it will report an error. BFdev offers a stack of 65536 entries, that means you can nest procedures until a depth of 65536. There is no stack overflow checking. This doesn't mean BFdev crashes if the stack grows too big, but instead, your program crashes and you probably wouldn't know why. The IDE itself doesn't crash when the stack overflows (I cared for this).

You can enable or disable pbrain support by checking or unchecking "Enable Procedural BF" in the "Interpreter" menu, by pressing Ctrl+P, or by clicking the pbrain button in the tool bar.

Version history

Brainfuck links

last modified: 18 Jan 2010