Version 93 (modified by benl, 7 years ago)


The Disciplined Disciple Compiler (DDC)

Disciple is a dialect of Haskell that uses strict evaluation as the default and supports destructive update of arbitrary data structures. Sequencing of effectful computations is achieved via effect typing, instead of with Monads such as ST and IO. Laziness is supported via programmer annotations, and the effect system guarantees that computations with visible side effects are not suspended. Many Haskell programs are also Disciple programs, or will run with minor changes. Our target applications are the ones that you always find yourself writing C programs for, because existing functional languages are too slow, use too much memory, or don't let you update the data that you need to.

DDC is still in the "research prototype" stage, meaning that it will compile programs if you are nice to it, but expect compiler panics and missing features. You'll get panics due to ungraceful handling of errors in the source code, but valid programs should compile ok. Here are some working examples, along with their Disciple source code:

Ray Tracer N-Body Styrene
Error: Macro Image(WikiStart:raytracer-thumb.png) failed
Attachment 'wiki:WikiStart: raytracer-thumb.png' does not exist.
Error: Macro Image(WikiStart:nbody-thumb.png) failed
Attachment 'wiki:WikiStart: nbody-thumb.png' does not exist.
Error: Macro Image(WikiStart:styrene-thumb.png) failed
Attachment 'wiki:WikiStart: styrene-thumb.png' does not exist.
(code) (code) (code)

State of Play

This section records what the DDC developers are actively working on. If you're hacking on something DDC related then by all means add yourself here. Records are dropped off if they haven't been updated for more than a month.

Ben Lippmeier (benl23) -- updated 20th September 2010

  • I've fixed inference of Shape constraints to respect the materiality of variables. This means we can now write copy functions for data structures containing functions.
  • I've cleaned up the array and numeric type modules in the base libraries.
  • Next step is to check the types of type class instance functions against their definitions, which should eliminate the main cause of confusing compiler panics.

Erik de Castro Lopo (m3ga) -- updated 18th Aug 2010

  • Started work on an LLVM backend. The idea is to have a -via-llvm command line option which would then generate object files using LLVM. The LLVM generated object files will be compatible with the object files generated using the C backend for easier debugging. Another goal for the backend is to make it easier to bootstrap the compiler (compile DDC with DDC) and to port the compiler to new platforms and architectures.
  • I'm pretty much stalled on all the current bugs and waiting for Ben to finish the refactoring at which time I'll have another crack at them.
  • Improvements to DDC's library.


Language Overview

Syntactic differences to Haskell

The Language Definition is still evolving, but the wiki should be in sync with the development branch.



How you can help

  • Download the compiler, write programs, and file bug reports!
  • Write more tests. Cute graphical demos are especially fun.
  • Fix bugs! The ones on the newbie list should be easy to get started on, otherwise we're pushing for the 0.1.3 release
  • 'port across GHC base libraries like Data.Either and Data.Map.

How to get help

Further Reading