All Projects → doctorn → Micro Mitten

doctorn / Micro Mitten

Licence: gpl-2.0
You might not need your garbage collector

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to Micro Mitten

o1heap
Constant-complexity deterministic memory allocator (heap) for hard real-time high-integrity embedded systems
Stars: ✭ 119 (-74.68%)
Mutual labels:  memory-management
Devito
Code generation framework for automated finite difference computation
Stars: ✭ 285 (-39.36%)
Mutual labels:  compilers
Sinsofmemoryleaks
Some common patterns of memory leaks in Android development and how to fix/avoid them
Stars: ✭ 343 (-27.02%)
Mutual labels:  memory-management
real-world-idris
Malfunction backend for Idris with a FFI to OCaml
Stars: ✭ 26 (-94.47%)
Mutual labels:  compilers
Heap Layers
Heap Layers: An Extensible Memory Allocation Infrastructure
Stars: ✭ 260 (-44.68%)
Mutual labels:  memory-management
Hellscape
GIMPLE obfuscator for C, C++, Go, ... all supported GCC targets and front-ends that use GIMPLE.
Stars: ✭ 298 (-36.6%)
Mutual labels:  compilers
awesome-internals
A curated list of awesome resources and learning materials in the field of X internals
Stars: ✭ 78 (-83.4%)
Mutual labels:  compilers
Scalene
Scalene: a high-performance, high-precision CPU, GPU, and memory profiler for Python
Stars: ✭ 4,819 (+925.32%)
Mutual labels:  memory-management
Structlayout
Visual Studio Extension for C++ struct memory layout visualization
Stars: ✭ 270 (-42.55%)
Mutual labels:  memory-management
Como Lang Ng
como-lang-ng is now ana-lang, located at https://github.com/analang/ana
Stars: ✭ 342 (-27.23%)
Mutual labels:  compilers
Compilingtheory
My course design for compiler theory (Visualization).
Stars: ✭ 257 (-45.32%)
Mutual labels:  compilers
Stringsareevil
Reducing memory allocations from 7.5GB to 32KB
Stars: ✭ 260 (-44.68%)
Mutual labels:  memory-management
Jemalloc.net
A native memory manager for .NET
Stars: ✭ 308 (-34.47%)
Mutual labels:  memory-management
cs-resources
Curated Computer Science and Programming Resource Guide
Stars: ✭ 42 (-91.06%)
Mutual labels:  compilers
Mps
The Memory Pool System
Stars: ✭ 351 (-25.32%)
Mutual labels:  memory-management
3bc-lang
Low level language, tiny virtual machine that works on computers and microcontrollers. (Friendly Punched cards)
Stars: ✭ 155 (-67.02%)
Mutual labels:  compilers
Osx Gcc Installer
GCC Installer for OSX! Without Xcode!
Stars: ✭ 3,078 (+554.89%)
Mutual labels:  compilers
Simd Visualiser
A tool to graphically visualize SIMD code
Stars: ✭ 459 (-2.34%)
Mutual labels:  compilers
Compilers Targeting C
A list of compilers that can generate C code
Stars: ✭ 385 (-18.09%)
Mutual labels:  compilers
Kgt
BNF wrangling and railroad diagrams
Stars: ✭ 312 (-33.62%)
Mutual labels:  compilers

micro-mitten

metal's too hot? wear a mitten!

Build Status

micro-mitten??

micro-mitten is a bare-bones Rust-like programming language, stripped down to simplify control-flow structures and the type system.

Like Rust, micro-mitten offers a static approach to memory management; however, micro-mitten's approach is significantly different from Rust's. Rather than depending on single ownership and a complex lifetime system, micro-mitten uses a series of data-flow analyses to statically approximate heap liveness. This means that it maintains the ability to insert freeing code at appropriate program points, without putting restrictions on how you write your code. The theory behind the approach is documented in this thesis (Proust 2017).

Long story short, this is an attempt to see if we really can have unrestrictive compile-time garbage collection.

How can I use it?!

The project depends on libgc and the LLVM-8 toolchain. Cloning this repository and running the following should get you set up with a working copy of mmtnc (the micro-mitten compiler).

./tools.sh # installs `mitten-test`, `mitten-bench`, `knit` and the language runtime
cargo install --path ./ --force # installs `mmtnc`

mmtnc compiles .mmtn files to LLVM IR (.ll) and just dumps the textual representation. Much more helpfully, you can get binaries directly using knit. To build a binary (example) from a source file (example.mmtn) use:

knit --src example.mmtn --gc-strategy=proust 

The --gc-strategy argument is optional, but the default is to use no garbage collection (your computer will hate you). The other options are proust (uses static memory management) and bdw (uses libgc).

Notes

To get an idea of the language syntax, check out the examples in src/test/. If you get something wrong, the compiler should moan at you. Otherwise, please open an issue!

Please note, micro-mitten is purely a research language and its performance is not brilliant when using static memory management. For a full run-down, see my dissertation. Most of the examples in src/test/ will run with static memory management, but there are some notable exceptions and one or two memory leaks.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].