Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/csjh/mite
A high performance language for Javascript accompaniment
https://github.com/csjh/mite
compiler javascript language programming-language webassembly
Last synced: about 2 months ago
JSON representation
A high performance language for Javascript accompaniment
- Host: GitHub
- URL: https://github.com/csjh/mite
- Owner: csjh
- License: mit
- Created: 2023-09-21T02:15:23.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-05-22T04:20:44.000Z (8 months ago)
- Last Synced: 2024-05-22T12:44:23.312Z (8 months ago)
- Topics: compiler, javascript, language, programming-language, webassembly
- Language: TypeScript
- Homepage:
- Size: 428 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# The Mite Programming Language
Mite is a programming language designed as a high-performance language to accompany Javascript. It compiles to a small, (hopefully) efficient WebAssembly binary using the binaryen toolchain. A major goal of the project is to keep language features to a minimum to prevent binary size bloat.
The compiler is written in Typescript at the moment, with plans to port it to C++ after a solid baseline PoC is established. The language itself is mostly inspired by C, with some other modern features that add minimal overhead which I find useful in other languages.
Mite was made to accompany my learning during my introduction to C university course, and is not intended for production use. Currently, it is not anywhere near feature complete.
## Features
- All the basic arithmetic, logical, comparison, and bitwise operators
- Variables
- Functions
- If, for, while, do-while expressions
- Stack-allocated structs, arrays
- First class SIMD support## Roadmap
> In no particular order
- [x] 0-copy Mite -> Javascript Interop (other than strings)
- [x] Javascript Helper Mode
- [ ] Standard Library
- [ ] Closures
- [ ] C++ Port
- [x] Heap [^1]
- [ ] (Graph-based?) IR for optimzations
- [x] Strings [^2][^1]: A traditional heap (with malloc and free and stuff) is kinda iffy right now, unsure of where it will land atm.
[^2]: This might be pending for the WebAssembly story for strings to be figured out. Right now it seems like one of `stringref` or `JS String Builtins`. String builtins could be polyfilled (albeit possibly slowly), so for now they might be what I go with.